nvim: copilot and chatgpt
This commit is contained in:
parent
5f0e861fdd
commit
fbdda9d41f
|
|
@ -0,0 +1,3 @@
|
||||||
|
require("chatgpt").setup({
|
||||||
|
api_key_cmd = "pass api/chatgpt_neovim",
|
||||||
|
})
|
||||||
|
|
@ -21,15 +21,15 @@ cmp.setup {
|
||||||
behavior = cmp.ConfirmBehavior.Replace,
|
behavior = cmp.ConfirmBehavior.Replace,
|
||||||
select = true,
|
select = true,
|
||||||
},
|
},
|
||||||
['<Tab>'] = cmp.mapping(function(fallback)
|
--['<Tab>'] = cmp.mapping(function(fallback)
|
||||||
if cmp.visible() then
|
-- if cmp.visible() then
|
||||||
cmp.select_next_item()
|
-- cmp.select_next_item()
|
||||||
elseif luasnip.expand_or_jumpable() then
|
-- elseif luasnip.expand_or_jumpable() then
|
||||||
luasnip.expand_or_jump()
|
-- luasnip.expand_or_jump()
|
||||||
else
|
-- else
|
||||||
fallback()
|
-- fallback()
|
||||||
end
|
-- end
|
||||||
end, { 'i', 's' }),
|
--end, { 'i', 's' }),
|
||||||
['<S-Tab>'] = cmp.mapping(function(fallback)
|
['<S-Tab>'] = cmp.mapping(function(fallback)
|
||||||
if cmp.visible() then
|
if cmp.visible() then
|
||||||
cmp.select_prev_item()
|
cmp.select_prev_item()
|
||||||
|
|
|
||||||
|
|
@ -26,5 +26,18 @@ return require('packer').startup(function(use)
|
||||||
use 'lukas-reineke/indent-blankline.nvim'
|
use 'lukas-reineke/indent-blankline.nvim'
|
||||||
|
|
||||||
use 'lewis6991/gitsigns.nvim'
|
use 'lewis6991/gitsigns.nvim'
|
||||||
|
use 'github/copilot.vim'
|
||||||
|
|
||||||
|
use({
|
||||||
|
"jackMort/ChatGPT.nvim",
|
||||||
|
config = function()
|
||||||
|
require("chatgpt").setup()
|
||||||
|
end,
|
||||||
|
requires = {
|
||||||
|
"MunifTanjim/nui.nvim",
|
||||||
|
"nvim-lua/plenary.nvim",
|
||||||
|
"nvim-telescope/telescope.nvim"
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
end)
|
end)
|
||||||
|
|
|
||||||
|
|
@ -95,6 +95,11 @@ _G.packer_plugins = {
|
||||||
path = "/home/dm/.local/share/nvim/site/pack/packer/start/cmp_luasnip",
|
path = "/home/dm/.local/share/nvim/site/pack/packer/start/cmp_luasnip",
|
||||||
url = "https://github.com/saadparwaiz1/cmp_luasnip"
|
url = "https://github.com/saadparwaiz1/cmp_luasnip"
|
||||||
},
|
},
|
||||||
|
["copilot.vim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/dm/.local/share/nvim/site/pack/packer/start/copilot.vim",
|
||||||
|
url = "https://github.com/github/copilot.vim"
|
||||||
|
},
|
||||||
["gitsigns.nvim"] = {
|
["gitsigns.nvim"] = {
|
||||||
loaded = true,
|
loaded = true,
|
||||||
path = "/home/dm/.local/share/nvim/site/pack/packer/start/gitsigns.nvim",
|
path = "/home/dm/.local/share/nvim/site/pack/packer/start/gitsigns.nvim",
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue