~xdavidwu/dotfiles

4b61a89c7a578edd687b052e83c8ebf2baaea638 — xdavidwu 2 years ago 53ba643
vim: add cursor position remembering for nvim
1 files changed, 6 insertions(+), 0 deletions(-)

M .config/vim/vimrc
M .config/vim/vimrc => .config/vim/vimrc +6 -0
@@ 41,3 41,9 @@ autocmd User ALELintPost let tmp=ale#statusline#Count(bufnr(''))['total'] | set 
autocmd InsertEnter * silent !echo -en "\e[?737769h"
autocmd InsertLeave * silent !echo -en "\e[?737769l"
autocmd VimLeave * silent !echo -en "\e[?737769h"
if has('nvim')
	autocmd BufReadPost *
		\ if line("'\"") >= 1 && line("'\"") <= line("$") && &ft !~# 'commit'
		\ |   exe "normal! g`\""
		\ | endif
endif