aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEugene Triguba <eugenetriguba@gmail.com>2025-06-28 00:57:12 -0400
committerEugene Triguba <eugenetriguba@gmail.com>2025-06-28 00:57:12 -0400
commit4f051dac80b45a873f36e53c50347814d1b31aeb (patch)
treee1fd40d0bdd37f373af18231789ee25ec6adb468
parentRemove ensure symlink exists (diff)
downloaddotfiles-4f051dac80b45a873f36e53c50347814d1b31aeb.zip
Add copilot
-rw-r--r--nvim/.config/nvim/lazy-lock.json2
-rw-r--r--nvim/.config/nvim/lua/plugins/blink.lua9
-rw-r--r--nvim/.config/nvim/lua/plugins/conform.lua1
-rw-r--r--nvim/.config/nvim/lua/plugins/copilot.lua27
-rw-r--r--nvim/.config/nvim/lua/plugins/lint.lua1
5 files changed, 39 insertions, 1 deletions
diff --git a/nvim/.config/nvim/lazy-lock.json b/nvim/.config/nvim/lazy-lock.json
index 328723c..bfee37a 100644
--- a/nvim/.config/nvim/lazy-lock.json
+++ b/nvim/.config/nvim/lazy-lock.json
@@ -1,6 +1,8 @@
{
+ "CopilotChat.nvim": { "branch": "main", "commit": "55f2162c36901224e22ff8424fd60ecef670b8fc" },
"LuaSnip": { "branch": "master", "commit": "458560534a73f7f8d7a11a146c801db00b081df0" },
"barbar.nvim": { "branch": "master", "commit": "53b5a2f34b68875898f0531032fbf090e3952ad7" },
+ "blink-cmp-copilot": { "branch": "main", "commit": "439cff78780c033aa23cf061d7315314b347e3c1" },
"blink.cmp": { "branch": "main", "commit": "9bcb14b43852a6f2bfd5ac9ef29cb5cf09b1b39b" },
"conform.nvim": { "branch": "master", "commit": "8132ec733eed3bf415b97b76797ca41b59f51d7d" },
"copilot.lua": { "branch": "master", "commit": "46f4b7d026cba9497159dcd3e6aa61a185cb1c48" },
diff --git a/nvim/.config/nvim/lua/plugins/blink.lua b/nvim/.config/nvim/lua/plugins/blink.lua
index 9df552a..e035292 100644
--- a/nvim/.config/nvim/lua/plugins/blink.lua
+++ b/nvim/.config/nvim/lua/plugins/blink.lua
@@ -32,6 +32,7 @@ return {
opts = {},
},
'folke/lazydev.nvim',
+ 'giuxtaposition/blink-cmp-copilot',
},
--- @module 'blink.cmp'
--- @type blink.cmp.Config
@@ -77,9 +78,15 @@ return {
},
sources = {
- default = { 'lsp', 'path', 'snippets', 'lazydev' },
+ default = { 'lsp', 'path', 'snippets', 'lazydev', 'copilot' },
providers = {
lazydev = { module = 'lazydev.integrations.blink', score_offset = 100 },
+ copilot = {
+ name = 'copilot',
+ module = 'blink-cmp-copilot',
+ score_offset = 100,
+ async = true,
+ },
},
},
diff --git a/nvim/.config/nvim/lua/plugins/conform.lua b/nvim/.config/nvim/lua/plugins/conform.lua
index 169a0cd..1d4be80 100644
--- a/nvim/.config/nvim/lua/plugins/conform.lua
+++ b/nvim/.config/nvim/lua/plugins/conform.lua
@@ -77,6 +77,7 @@ return {
css = { 'prettierd', 'prettier', stop_after_first = true },
htmldjango = { 'prettierd', 'prettier', stop_after_first = true },
html = { 'prettierd', 'prettier', stop_after_first = true },
+ sh = { 'shfmt' },
},
formatters = {
isort = {
diff --git a/nvim/.config/nvim/lua/plugins/copilot.lua b/nvim/.config/nvim/lua/plugins/copilot.lua
new file mode 100644
index 0000000..4d16709
--- /dev/null
+++ b/nvim/.config/nvim/lua/plugins/copilot.lua
@@ -0,0 +1,27 @@
+return {
+ {
+ 'zbirenbaum/copilot.lua',
+ cmd = 'Copilot',
+ event = 'InsertEnter',
+ config = function()
+ require('copilot').setup {
+ suggestion = { enabled = false },
+ panel = { enabled = false },
+ }
+ end,
+ },
+ {
+ 'CopilotC-Nvim/CopilotChat.nvim',
+ dependencies = {
+ { 'zbirenbaum/copilot.lua' },
+ { 'nvim-lua/plenary.nvim', branch = 'master' }, -- for curl, log and async functions
+ },
+ build = 'make tiktoken', -- Only on MacOS or Linux
+ config = function()
+ require('CopilotChat').setup {}
+ vim.keymap.set('n', '<leader>cc', function()
+ vim.cmd 'CopilotChatToggle'
+ end, { desc = '[Copilot] Toggle Copilot Chat' })
+ end,
+ },
+}
diff --git a/nvim/.config/nvim/lua/plugins/lint.lua b/nvim/.config/nvim/lua/plugins/lint.lua
index 3b39c05..ed5679b 100644
--- a/nvim/.config/nvim/lua/plugins/lint.lua
+++ b/nvim/.config/nvim/lua/plugins/lint.lua
@@ -14,6 +14,7 @@ return {
lint.linters_by_ft['terraform'] = { 'tflint' }
lint.linters_by_ft['python'] = { 'ruff', 'bandit' }
lint.linters_by_ft['markdown'] = nil
+ lint.linters_by_ft['sh'] = { 'shellcheck' }
-- Default linters, which will cause errors unless these tools are available:
-- {