mirror of
https://github.com/ItsDrike/dotfiles.git
synced 2025-06-30 12:30:43 +00:00
Update vim config
This commit is contained in:
parent
49b1fb917e
commit
1de5142b86
3 changed files with 28 additions and 12 deletions
|
@ -2,7 +2,7 @@
|
|||
"set viminfofile=$XDG_CACHE_HOME/vim/viminfo
|
||||
|
||||
" Disable automatic commenting on newline
|
||||
autocmd FileType * setlocal formatoptions-=c formatoptions-=r formatoptions-=o
|
||||
autocmd FileType * setlocal formatoptions-=cro
|
||||
|
||||
" Have Vim jump to the last position when reopening a file
|
||||
autocmd BufReadPost * if line("'\"") > 1 && line("'\"") <= line("$") | exe "normal! g'\"" | endif
|
||||
|
@ -10,3 +10,6 @@ autocmd BufReadPost * if line("'\"") > 1 && line("'\"") <= line("$") | exe "norm
|
|||
" Automatically deletes all trailing whitespace on save
|
||||
autocmd BufWritePre * %s/\s\+$//e
|
||||
|
||||
" Enable spellcheck for certain file types
|
||||
autocmd FileType tex,latex,markdown,gitcommit setlocal spell spelllang=en_us
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue