|
|
|
@ -62,22 +62,20 @@ nmap <silent> <Leader><Space> :SK<CR>
|
|
|
|
|
" }}} |
|
|
|
|
|
|
|
|
|
" Polyglot {{{ |
|
|
|
|
let g:polyglot_disabled = ["csv"] |
|
|
|
|
" let g:polyglot_disabled = ["csv"] |
|
|
|
|
let g:polyglot_disabled = ['sensible'] |
|
|
|
|
" }}} |
|
|
|
|
|
|
|
|
|
" }}} |
|
|
|
|
|
|
|
|
|
" Filetype specific configurations {{{ |
|
|
|
|
" Vim files {{{ |
|
|
|
|
augroup vim |
|
|
|
|
au FileType vim setlocal noexpandtab " use real tabs |
|
|
|
|
au FileType vim setlocal tabstop=4 " display tabs as 4 spaces |
|
|
|
|
au FileType vim setlocal shiftwidth=4 " Use 4 spaces when auto-indenting |
|
|
|
|
augroup END |
|
|
|
|
" }}} |
|
|
|
|
|
|
|
|
|
" Python {{{ |
|
|
|
|
augroup python |
|
|
|
|
au FileType python setlocal number " show line numbers |
|
|
|
|
au FileType python setlocal expandtab " use spaces instead of tabs |
|
|
|
|
au FileType python setlocal tabstop=4 " number of spaces to use for indentation |
|
|
|
@ -90,21 +88,17 @@ augroup python
|
|
|
|
|
|
|
|
|
|
" Shortcut to add pylint disables |
|
|
|
|
au FileType python iab lint # pylint: disable |
|
|
|
|
au FileType python iab defmain def main():<CR>""""""<CR><CR><BS>if __name__ == '__main__':<CR>main()<up><up><up><left><left><left> |
|
|
|
|
augroup END |
|
|
|
|
" au FileType python iab defmain def main():<CR>""""""<CR><CR><BS>if __name__ == '__main__':<CR>main()<up><up><up><left><left><left> |
|
|
|
|
" }}} |
|
|
|
|
|
|
|
|
|
" CSV files {{{ |
|
|
|
|
augroup csv |
|
|
|
|
au FileType csv setlocal list " Display special characters, like tabs (for TSV files) |
|
|
|
|
augroup END |
|
|
|
|
" }}} |
|
|
|
|
|
|
|
|
|
" Rust {{{ |
|
|
|
|
" Apply `rustfmt` when saving the file. Because this is related to the syntax |
|
|
|
|
" file and not something on the buffer itself, we can set it globally. |
|
|
|
|
let g:rustfmt_autosave = 1 |
|
|
|
|
augroup rust |
|
|
|
|
|
|
|
|
|
let g:rustfmt_autosave = 1 " Apply `rustfmt` when saving the file. |
|
|
|
|
|
|
|
|
|
au FileType rust setlocal number " show line numbers |
|
|
|
|
au FileType rust setlocal expandtab " use spaces instead of tabs |
|
|
|
|
au FileType rust setlocal tabstop=4 " number of spaces to use for indentation |
|
|
|
@ -112,11 +106,9 @@ augroup rust
|
|
|
|
|
au FileType rust setlocal softtabstop=4 " when deleting characters, consider 4 spaces as a tab |
|
|
|
|
au FileType rust setlocal textwidth=79 " max line size |
|
|
|
|
au FileType rust setlocal colorcolumn=80 " put a margin indicator |
|
|
|
|
augroup END |
|
|
|
|
" }}} |
|
|
|
|
|
|
|
|
|
" Markdown {{{ |
|
|
|
|
augroup markdown |
|
|
|
|
au FileType markdown setlocal iskeyword+=: " this is kinda of a "hack" to make abbr accept ":" in them |
|
|
|
|
" This is a long abbreviation, but: |
|
|
|
|
" Most of it is simply text, with linebreaks (<CR>). |
|
|
|
@ -132,14 +124,11 @@ augroup markdown
|
|
|
|
|
au FileType markdown setlocal spell " enable spell checking |
|
|
|
|
au FileType markdown setlocal textwidth=79 " max line size |
|
|
|
|
au FileType markdown setlocal expandtab " use spaces instead of tabs |
|
|
|
|
augroup END |
|
|
|
|
" }}} |
|
|
|
|
|
|
|
|
|
" Shell {{{ |
|
|
|
|
augroup shell |
|
|
|
|
au FileType sh setlocal tabstop=4 " display tabs as 4 spaces |
|
|
|
|
au FileType sh setlocal shiftwidth=4 " number of spaces to use for auto-indentation |
|
|
|
|
au FileType sh setlocal softtabstop=4 " when deleting characters, consider 4 spaces as a tab |
|
|
|
|
augroup END |
|
|
|
|
" }}} |
|
|
|
|
" }}} |
|
|
|
|