-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.vimrc
67 lines (53 loc) · 2 KB
/
.vimrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
set nocompatible " be iMproved, required
filetype on
filetype off " required
" -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
" https://github.com/junegunn/vim-plug
call plug#begin('~/.vim/plugged')
" https://wakatime.com/
Plug 'wakatime/vim-wakatime'
" https://github.com/bronson/vim-trailing-whitespace
Plug 'bronson/vim-trailing-whitespace'
" https://github.com/fatih/vim-go
Plug 'fatih/vim-go'
" https://github.com/godlygeek/tabular
Plug 'godlygeek/tabular'
" https://github.com/plasticboy/vim-markdown
Plug 'plasticboy/vim-markdown'
call plug#end()
" -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
filetype plugin on
set expandtab
set tabstop=4
set shiftwidth=4
autocmd BufNewFile,BufReadPost *.yml set filetype=yaml
autocmd BufNewFile,BufReadPost *.json set filetype=json
autocmd BufNewFile,BufReadPost *.jbuilder set filetype=ruby
autocmd BufNewFile,BufReadPost *.vue set filetype=javascript
autocmd FileType html setlocal ts=2 sw=2
autocmd FileType css setlocal ts=2 sw=2
autocmd FileType yaml setlocal ts=2 sw=2
autocmd FileType json setlocal ts=2 sw=2
autocmd FileType javascript setlocal ts=2 sw=2
autocmd FileType ruby setlocal ts=2 sw=2
autocmd FileType python setlocal ts=4 sw=4
autocmd FileType php setlocal ts=4 sw=4
autocmd FileType ts setlocal ts=4 sw=4
autocmd FileType java setlocal ts=4 sw=4
autocmd FileType groovy setlocal ts=4 sw=4
autocmd FileType kotlin setlocal ts=4 sw=4
autocmd FileType scala setlocal ts=2 sw=4
autocmd FileType go setlocal noexpandtab ts=4 sw=4
autocmd FileType * setlocal formatoptions-=cro
syntax enable
" WTF for MacBook Pro
imap jj <Esc>
" Go Programming Language
let g:go_fmt_command = "goimports"
let g:go_highlight_types = 1
let g:go_highlight_functions = 1
let g:go_highlight_function_calls = 1
let g:go_highlight_operators = 1
let g:go_highlight_extra_types = 1
" Markdown
let g:vim_markdown_folding_disabled = 1