task: Add copilot

This commit is contained in:
Viorel Binciu 2025-09-16 13:46:14 +03:00
parent 6a1c419aa4
commit fa121c8727
No known key found for this signature in database
GPG key ID: AC875EA6A34E7770

View file

@ -0,0 +1,22 @@
return {
{
"CopilotC-Nvim/CopilotChat.nvim",
dependencies = {
{ "github/copilot.vim" },
{ "nvim-lua/plenary.nvim", branch = "master" },
},
build = "make tiktoken",
opts = {},
keys = {
{ "<leader>zc", ":CopilotChat<CR>", mode = "n", desc = "Chat with Copilot" },
{ "<leader>ze", ":CopilotChatExplain<CR>", mode = "v", desc = "Explain Code" },
{ "<leader>zn", ":CopilotChatReview<CR>", mode = "v", desc = "Review Code" },
{ "<leader>zf", ":CopilotChatFix<CR>", mode = "v", desc = "Fix Code Issues" },
{ "<leader>zo", ":CopilotChatOptimize<CR>", mode = "v", desc = "Optimize Code" },
{ "<leader>zd", ":CopilotChatDocs<CR>", mode = "v", desc = "Generate Docs" },
{ "<leader>zt", ":CopilotChatTests<CR>", mode = "v", desc = "Generate Tests" },
{ "<leader>zm", ":CopilotChatCommit<CR>", mode = "n", desc = "Generate Commit Message" },
{ "<leader>zs", ":CopilotChatCommit<CR>", mode = "v", desc = "Generate Commit for Selection" },
},
},
}