diff --git a/lua/astrocommunity/completion/copilot-lua-cmp/copilot-lua-cmp.lua b/lua/astrocommunity/completion/copilot-lua-cmp/copilot-lua-cmp.lua index 9ad9fb596..38e5631a2 100644 --- a/lua/astrocommunity/completion/copilot-lua-cmp/copilot-lua-cmp.lua +++ b/lua/astrocommunity/completion/copilot-lua-cmp/copilot-lua-cmp.lua @@ -39,6 +39,26 @@ return { if copilot.is_visible() then copilot.prev() end end) + opts.mapping[""] = cmp.mapping(function() + if copilot.is_visible() then copilot.accept_word() end + end) + + opts.mapping[""] = cmp.mapping(function() + if copilot.is_visible() then copilot.accept_word() end + end) + + opts.mapping[""] = cmp.mapping(function() + if copilot.is_visible() then copilot.accept_line() end + end) + + opts.mapping[""] = cmp.mapping(function() + if copilot.is_visible() then copilot.accept_line() end + end) + + opts.mapping[""] = cmp.mapping(function() + if copilot.is_visible() then copilot.dismiss() end + end) + return opts end, },