vim/plugin/autocmds.vim

16 lines
523 B
VimL

augroup benieAugroup
" Clear all autocmd's in this group
autocmd!
" Reopening a file at last curson position
au BufReadPost * if line("'\"") > 0 && line("'\"") <= line("$")
\ | exe "normal! g'\"" | endif
" TODO: Move this to a plugin & rename to .enter .exit
au BufRead,BufNewFile .env set filetype=zsh
au BufRead,BufNewFile .out set filetype=zsh
" Highlight conflict markers in any filefile
au FileType * :call matchadd('Todo', '^\(<<<<<<<\||||||||\|=======\|>>>>>>>\)\s\ze.*$')
augroup END