aboutsummaryrefslogtreecommitdiffstats
path: root/nvim
diff options
context:
space:
mode:
authorMatthew Lemon <y@yulqen.org>2023-04-09 09:06:18 +0100
committerMatthew Lemon <y@yulqen.org>2023-04-09 09:06:18 +0100
commitb0ed665496a280987b2406c9c497446a5f522c29 (patch)
tree673dab7a2847fd947d17b591486a2cb16d90585b /nvim
parentbcab2ba0b1fe704145b8479e66b3c46177ed669f (diff)
Add Github Copilot configuration
I have taken the plunge!
Diffstat (limited to 'nvim')
-rw-r--r--nvim/after/plugin/copilot.lua17
1 files changed, 17 insertions, 0 deletions
diff --git a/nvim/after/plugin/copilot.lua b/nvim/after/plugin/copilot.lua
new file mode 100644
index 0000000..f993a93
--- /dev/null
+++ b/nvim/after/plugin/copilot.lua
@@ -0,0 +1,17 @@
+vim.g.copilot_no_tab_map = true
+vim.api.nvim_set_keymap("i", "<C-J>", 'copilot#Accept("<CR>")', { silent = true, expr = true })
+-- not working vim.g.copilot_assume_mapped = true
+
+vim.g.copilot_filetypes = {
+ ["*"] = false,
+ ["markdown"] = true,
+ ["javascript"] = false,
+ ["typescript"] = false,
+ ["lua"] = true,
+ ["rust"] = true,
+ ["c"] = true,
+ ["c#"] = true,
+ ["c++"] = true,
+ ["go"] = true,
+ ["python"] = true,
+}