1
0

Show cursorline when not in insert mode

This commit is contained in:
Patrick Auernig 2023-07-18 15:21:42 +02:00
parent 83c8633436
commit 67b90b9f1e
2 changed files with 8 additions and 1 deletions

View File

@ -10,6 +10,13 @@ vim.opt.scrolloff = 8
vim.opt.signcolumn = "yes"
vim.opt.colorcolumn = "100"
vim.api.nvim_create_autocmd({"InsertEnter", "InsertLeave", "BufEnter"}, {
callback = function(args)
local entered_insert_mode = args.event == "InsertEnter"
vim.opt.cursorline = not entered_insert_mode
end
})
-- yank to clipboard, requires wl-copy command or equivalent
vim.opt.clipboard:append("unnamedplus")

View File

@ -5,7 +5,7 @@ telescope.load_extension("harpoon")
telescope.setup {
defaults = {
initial_mode = "normal"
initial_mode = "insert"
},
pickers = {
buffers = {