-
Notifications
You must be signed in to change notification settings - Fork 0
/
vimrc
58 lines (48 loc) · 1.48 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
set nocompatible
syntax on
set showmode
set showmatch
set ruler
set showcmd
set incsearch
set hlsearch
set backspace=2
set visualbell
"Highlight text over 80 chars
au BufNewFile,BufRead *.vimrc,*.c,*.cc,*.h,*.java,*.py,*.rules match TooLong /\%<82v.\%>81v/
hi link TooLong Warning
hi Warning ctermbg=Grey ctermfg=DarkRed
let g:jsx_ext_required = 0
call plug#begin('~/.vim/plugged')
Plug 'pangloss/vim-javascript'
Plug 'mxw/vim-jsx'
Plug 'w0rp/ale'
Plug 'altercation/vim-colors-solarized'
Plug 'google/vim-maktaba'
Plug 'google/vim-codefmt'
Plug 'google/vim-glaive'
Plug 'nathangrigg/vim-beancount'
call plug#end()
let g:ale_fixers = {}
let g:ale_fixers['javascript'] = ['prettier']
let g:ale_fix_on_save = 1
let g:ale_sign_column_always = 1
set background=dark
colorscheme solarized
" workaround for mosh color issue
set termguicolors
call glaive#Install()
Glaive codefmt plugin[mappings]
augroup autoformat_settings
" autocmd FileType bzl AutoFormatBuffer buildifier
" autocmd FileType c,cpp,proto,javascript AutoFormatBuffer clang-format
" autocmd FileType dart AutoFormatBuffer dartfmt
" autocmd FileType go AutoFormatBuffer gofmt
" autocmd FileType gn AutoFormatBuffer gn
" autocmd FileType html,css,json AutoFormatBuffer js-beautify
" autocmd FileType java AutoFormatBuffer google-java-format
" autocmd FileType python AutoFormatBuffer yapf
" Alternative: autocmd FileType python AutoFormatBuffer autopep8
augroup END
set autoindent
set shiftwidth=4 expandtab softtabstop=4 tabstop=4