mirror of
https://github.com/dcarrillo/dotfiles.git
synced 2024-12-22 17:28:01 +00:00
[neovim] Update copilotchat keymaps
This commit is contained in:
parent
e7575a7c1f
commit
069882fcb8
@ -147,14 +147,20 @@ keymap(
|
|||||||
)
|
)
|
||||||
|
|
||||||
-- Copilot
|
-- Copilot
|
||||||
keymap({ "n", "v" }, "<leader>coa", function()
|
keymap({ "n", "v" }, "<leader>coh", function()
|
||||||
local actions = require("CopilotChat.actions")
|
local actions = require("CopilotChat.actions")
|
||||||
require("CopilotChat.integrations.telescope").pick(actions.help_actions())
|
require("CopilotChat.integrations.telescope").pick(actions.help_actions())
|
||||||
end, vim.tbl_extend("force", opts, { desc = "CopilotChat - Help actions" }))
|
end, vim.tbl_extend("force", opts, { desc = "CopilotChat - Help actions" }))
|
||||||
keymap("n", "<leader>coh", function()
|
keymap({ "n", "v" }, "<leader>cop", function()
|
||||||
local actions = require("CopilotChat.actions")
|
local actions = require("CopilotChat.actions")
|
||||||
require("CopilotChat.integrations.telescope").pick(actions.prompt_actions())
|
require("CopilotChat.integrations.telescope").pick(actions.prompt_actions())
|
||||||
end, vim.tbl_extend("force", opts, { desc = "CopilotChat - Prompt actions" }))
|
end, vim.tbl_extend("force", opts, { desc = "CopilotChat - Prompt actions" }))
|
||||||
|
keymap("n", "<leader>coq", function()
|
||||||
|
local input = vim.fn.input("Quick Chat: ")
|
||||||
|
if input ~= "" then
|
||||||
|
require("CopilotChat").ask(input, { selection = require("CopilotChat.select").buffer })
|
||||||
|
end
|
||||||
|
end, vim.tbl_extend("force", opts, { desc = "CopilotChat - Quick chat" }))
|
||||||
|
|
||||||
-- Better paste
|
-- Better paste
|
||||||
keymap("v", "p", "P", vim.tbl_extend("force", opts, { desc = "Paste" }))
|
keymap("v", "p", "P", vim.tbl_extend("force", opts, { desc = "Paste" }))
|
||||||
|
Loading…
Reference in New Issue
Block a user