Skip to content

Commit

Permalink
update copilot plugins
Browse files Browse the repository at this point in the history
  • Loading branch information
y011d4 committed Oct 15, 2024
1 parent 1cb7043 commit 38c42e1
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 3 deletions.
2 changes: 2 additions & 0 deletions .config/nvim/lua/nvim-cmp-setting.lua
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ cmp.setup({
end,
},
sources = cmp.config.sources({
{ name = "copilot", group_index = 2 },
{ name = "nvim_lsp" },
{ name = "luasnip" },
{ name = "treesitter" },
Expand Down Expand Up @@ -45,6 +46,7 @@ cmp.setup({
mode = 'symbol', -- show only symbol annotations
maxwidth = 50, -- prevent the popup from showing more than provided characters (e.g 50 will not show more than 50 characters)
ellipsis_char = '...', -- when popup menu exceed maxwidth, the truncated part would show ellipsis_char instead (must define maxwidth first)
symbol_map = { Copilot = "" },

-- The function below will be called before any actual modifications from lspkind
-- so that you can provide more controls on popup customization. (See [#30](https://github.com/onsails/lspkind-nvim/pull/30))
Expand Down
29 changes: 26 additions & 3 deletions .config/nvim/lua/plugins.lua
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ require("lazy").setup({
-- file を探したり文字列検索したり
{
"nvim-telescope/telescope.nvim",
tag = "0.1.6",
-- tag = "0.1.6",
dependencies = {
"nvim-lua/plenary.nvim",
"debugloop/telescope-undo.nvim",
Expand All @@ -250,6 +250,9 @@ require("lazy").setup({
vim.keymap.set("n", "<leader>fh", builtin.help_tags, {})
vim.keymap.set("n", "<leader>fr", builtin.resume, {})
vim.keymap.set("n", "<leader>fu", "<cmd>Telescope undo<cr>", {})
vim.keymap.set("n", "<leader>fd", builtin.diagnostics, {})
vim.keymap.set("n", "<leader>ft", builtin.treesitter, {})
vim.keymap.set("n", "<leader>f<cr>", builtin.builtin, {})
-- require("telescope").load_extension("undo")
require("telescope").setup({
extensions = {
Expand Down Expand Up @@ -458,6 +461,7 @@ require("lazy").setup({
"hrsh7th/cmp-path",
"hrsh7th/cmp-cmdline",
"ray-x/cmp-treesitter",
'zbirenbaum/copilot-cmp',
},
lazy = true,
event = "InsertEnter",
Expand Down Expand Up @@ -936,12 +940,12 @@ require("lazy").setup({
})
end
},
{
--[[ {
"github/copilot.vim",
config = function()
require("copilot-setting")
end
},
}, ]]
--[[ {
"Vigemus/iron.nvim",
config = function()
Expand Down Expand Up @@ -1089,5 +1093,24 @@ require("lazy").setup({
},
config = function()
end
},
{
"zbirenbaum/copilot.lua",
cmd = "Copilot",
event = "InsertEnter",
config = function()
require("copilot").setup({
suggestion = { enabled = false },
panel = { enabled = false },
})
end
},
{
'zbirenbaum/copilot-cmp',
lazy = true,
event = "InsertEnter",
config = function ()
require("copilot_cmp").setup()
end
}
})

0 comments on commit 38c42e1

Please sign in to comment.