🐛 fix(nvim): neocodeium now uses the cmp global variable to disable or enable
This commit is contained in:
parent
f9548065c7
commit
d28dec9274
1 changed files with 10 additions and 8 deletions
|
@ -2,19 +2,21 @@ return {
|
|||
"monkoose/neocodeium",
|
||||
event = "InsertEnter",
|
||||
config = function()
|
||||
local cmp = require("cmp")
|
||||
local neocodeium = require("neocodeium")
|
||||
neocodeium.setup()
|
||||
|
||||
local commands = require("neocodeium.commands")
|
||||
cmp.event:on("menu_opened", function()
|
||||
commands.disable()
|
||||
neocodeium.clear()
|
||||
end)
|
||||
if vim.g.codeium_cmp_hide == true then
|
||||
local cmp = require("cmp")
|
||||
cmp.event:on("menu_opened", function()
|
||||
commands.disable()
|
||||
neocodeium.clear()
|
||||
end)
|
||||
|
||||
cmp.event:on("menu_closed", function()
|
||||
commands.enable()
|
||||
end)
|
||||
cmp.event:on("menu_closed", function()
|
||||
commands.enable()
|
||||
end)
|
||||
end
|
||||
|
||||
vim.keymap.set("i", "<M-CR>", function()
|
||||
require("neocodeium").accept()
|
||||
|
|
Loading…
Add table
Reference in a new issue