Skip to content

Commit

Permalink
feat
Browse files Browse the repository at this point in the history
  • Loading branch information
ADGEfficiency committed Jan 29, 2025
1 parent 95d93f1 commit 4eb302f
Show file tree
Hide file tree
Showing 6 changed files with 58 additions and 62 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,3 @@ nvim/node_modules
nvim/temp*
nvim/package*
nvim/test*
nvim/plugin*
Empty file removed nvim/.gitignore
Empty file.
2 changes: 1 addition & 1 deletion nvim/lazy-lock.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"Vim-Jinja2-Syntax": { "branch": "master", "commit": "2c17843b074b06a835f88587e1023ceff7e2c7d1" },
"barbar.nvim": { "branch": "master", "commit": "c20691d686addb0d6ea87896d186c082324b01f8" },
"blink-cmp-dictionary": { "branch": "master", "commit": "07cc2e49bb52ebff4e8b83d1801ad6441edf90a2" },
"blink-copilot": { "branch": "main", "commit": "02daaf13654e78a6ec63401446d07f8c624f513b" },
"blink-emoji.nvim": { "branch": "master", "commit": "699493775b61b94ead76841c981a51d3df350ea0" },
"blink-ripgrep.nvim": { "branch": "main", "commit": "519ac7894113f6a7b517b157c26e31fbd58a0de5" },
"blink.cmp": { "branch": "main", "commit": "b6f11a0aa33e601c469a126e3ed6e35208fe3ea3" },
Expand All @@ -17,7 +18,6 @@
"cmp-pypi": { "branch": "main", "commit": "a73411e5935caa23c6feab34980bb435deadd482" },
"cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" },
"conform.nvim": { "branch": "master", "commit": "363243c03102a531a8203311d4f2ae704c620d9b" },
"copilot-cmp": { "branch": "master", "commit": "b6e5286b3d74b04256d0a7e3bd2908eabec34b44" },
"copilot.lua": { "branch": "master", "commit": "86537b286f18783f8b67bccd78a4ef4345679625" },
"dbtpal": { "branch": "main", "commit": "c526f65a65063c314d180e79df301b339f080236" },
"emmet-vim": { "branch": "master", "commit": "6c511a8d7d2863066f32e25543e2bb99d505172c" },
Expand Down
31 changes: 29 additions & 2 deletions nvim/lua/plugins/cmp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,12 @@ return {
dependencies = {
"echasnovski/mini.icons",
"mikavilpas/blink-ripgrep.nvim",
-- "giuxtaposition/blink-cmp-copilot",
"fang2hou/blink-copilot",
"moyiz/blink-emoji.nvim",
"rafamadriz/friendly-snippets",
"Kaiser-Yang/blink-cmp-dictionary",
dependencies = { "nvim-lua/plenary.nvim" },
"nvim-lua/plenary.nvim",
},
version = "*",

Expand Down Expand Up @@ -80,8 +82,33 @@ return {
-- Default list of enabled providers defined so that you can extend it
-- elsewhere in your config, without redefining it, due to `opts_extend`
sources = {
default = { "path", "lsp", "snippets", "buffer", "ripgrep", "emoji", "dictionary" },
default = {
"copilot",
"path",
"lsp",
"snippets",
"buffer",
"ripgrep",
"emoji",
"dictionary",
},
providers = {
-- copilot = {
-- name = "copilot",
-- module = "blink-cmp-copilot",
-- async = true,
-- score_offset = 100,
-- },
copilot = {
name = "copilot",
module = "blink-copilot",
score_offset = 100,
async = true,
opts = {
max_completions = 3,
max_attempts = 4,
},
},
buffer = {
name = "buffer",
module = "blink.cmp.sources.buffer",
Expand Down
84 changes: 27 additions & 57 deletions nvim/lua/plugins/copilot.lua
Original file line number Diff line number Diff line change
@@ -1,64 +1,34 @@
return {
{

"zbirenbaum/copilot.lua",
event = { "InsertEnter" },
config = function()
require("copilot").setup({
panel = {
enabled = false,
auto_refresh = true,
keymap = {
jump_prev = "[[",
jump_next = "]]",
accept = "<CR>",
refresh = "gr",
open = "<M-CR>",
},
layout = {
position = "bottom", -- | top | left | right
ratio = 0.4,
event = { "BufEnter" },
},
},
suggestion = {
enabled = false,
auto_trigger = false,
debounce = 75,
keymap = {
accept = "<M-l>",
accept_word = false,
accept_line = false,
next = "<M-]>",
prev = "<M-[>",
dismiss = "<C-]>",
},
},
filetypes = {
python = true,
markdown = true,
yaml = true,
help = false,
gitcommit = false,
gitrebase = false,
hgcommit = false,
svn = false,
cvs = false,
["*"] = true,
},
copilot_node_command = "node",
server_opts_overrides = {},
})
end,
},
{
"zbirenbaum/copilot-cmp",
event = { "BufEnter" },
dependencies = { "zbirenbaum/copilot.lua" },
config = function()
require("copilot_cmp").setup()
end,
cmd = "Copilot",
build = ":Copilot auth",
event = "InsertEnter",
opts = {
suggestion = { enabled = false },
panel = { enabled = false },
filetypes = {
python = true,
markdown = true,
yaml = true,
help = true,
gitcommit = false,
gitrebase = false,
hgcommit = false,
svn = false,
cvs = false,
["*"] = true,
},
},
},
-- {
-- "zbirenbaum/copilot-cmp",
-- event = { "BufEnter" },
-- dependencies = { "zbirenbaum/copilot.lua" },
-- config = function()
-- require("copilot_cmp").setup()
-- end,
-- },
{
"CopilotC-Nvim/CopilotChat.nvim",
branch = "canary",
Expand Down
2 changes: 1 addition & 1 deletion nvim/lua/plugins/linting.lua
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ return {
"mypy",
-- "flake8",
"pydocstyle",
"pylint",
-- "pylint",
},
sql = { "sqlfluff" },
yaml = { "actionlint", "yamllint" },
Expand Down

0 comments on commit 4eb302f

Please sign in to comment.