diff options
Diffstat (limited to 'nvim')
-rw-r--r-- | nvim/nvim/init.lua | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/nvim/nvim/init.lua b/nvim/nvim/init.lua index 4632a11..7bdec4a 100644 --- a/nvim/nvim/init.lua +++ b/nvim/nvim/init.lua @@ -45,6 +45,14 @@ vim.cmd.highlight("ExtraWhitespace", "ctermbg=red", "guibg=red") -- HighLight search vim.opt.hlsearch = true +-- Jump to latest position +vim.api.nvim_create_autocmd({ "BufReadPost" }, { + pattern = { "*" }, + callback = function() + vim.api.nvim_exec('silent! normal! g`"', false) + end, +}) + -- Whitespace local extraWhitespace = vim.api.nvim_create_augroup('whitespace', { clear = false }) vim.api.nvim_create_autocmd({"WinNew", "TabNew", "BufEnter", "InsertLeave"}, { |