disbable get to location after file load

This commit is contained in:
Oliver Hartmann 2022-07-01 21:14:12 +02:00
parent 23a3a8f7c6
commit d6f71c8ab2

View File

@ -57,10 +57,10 @@ api.nvim_create_autocmd({ 'FocusLost' }, { command = [[wshada]] })
api.nvim_create_autocmd({ 'FocusGained' }, { command = [[rshada]] }) api.nvim_create_autocmd({ 'FocusGained' }, { command = [[rshada]] })
-- go to last loc when opening a buffer -- go to last loc when opening a buffer
api.nvim_create_autocmd( -- api.nvim_create_autocmd(
'BufReadPost', -- 'BufReadPost',
{ command = [[if line("'\"") > 1 && line("'\"") <= line("$") | execute "normal! g`\"" | endif]] } -- { command = [[if line("'\"") > 1 && line("'\"") <= line("$") | execute "normal! g`\"" | endif]] }
) -- )
-- Check if we need to reload the file when it changed -- Check if we need to reload the file when it changed
api.nvim_create_autocmd({ 'FocusGained', 'BufEnter' }, { command = [[:checktime]] }) api.nvim_create_autocmd({ 'FocusGained', 'BufEnter' }, { command = [[:checktime]] })