1
0
Fork 0

.config/nvim: disable autocompletion (for now)

main
urosm 2024-07-15 20:49:39 +02:00
parent 0fa2ff7ba4
commit 5320b2053b
1 changed files with 13 additions and 12 deletions

View File

@ -55,7 +55,7 @@ opt.clipboard = "unnamedplus"
-- editing text -- editing text
opt.undofile = true opt.undofile = true
opt.textwidth = 80 opt.textwidth = 80
opt.completeopt = { "menuone", "preview", "noselect" } opt.completeopt = { "menuone", "preview" }
-- tabs and indenting -- tabs and indenting
opt.tabstop = 4 opt.tabstop = 4
@ -115,14 +115,15 @@ keymap_set("n", "<leader>.", "<cmd>edit .<cr>")
-- buffer autocomplete --------------------------------------------------------- -- buffer autocomplete ---------------------------------------------------------
local bufautocomplete_augroup = api.nvim_create_augroup("Buffer autocompletion", {}), -- @note disable autocompletion for now
api.nvim_create_autocmd("InsertCharPre", { -- local bufautocomplete_augroup = api.nvim_create_augroup("Buffer autocompletion", {}),
group = bufautocomplete_augroup, -- api.nvim_create_autocmd("InsertCharPre", {
pattern = "*", -- group = bufautocomplete_augroup,
callback = function () -- pattern = "*",
if fn.pumvisible() == 0 and v.char:find("%w") then -- callback = function ()
api.nvim_input("<c-n>") -- if fn.pumvisible() == 0 and v.char:find("%w") then
end -- api.nvim_input("<c-n>")
end, -- end
desc = "Buffer autocomplete on InsertCharPre", -- end,
}) -- desc = "Buffer autocomplete on InsertCharPre",
-- })