Remap Github Copilot Autocompletion
This commit is contained in:
parent
37808a6f6e
commit
76182ae8a0
|
@ -0,0 +1,12 @@
|
||||||
|
#!/bin/bash --login
|
||||||
|
if [[ $1 != "" && $2 != "" && $3 != "" ]]; then
|
||||||
|
# Default Strategy is to merge codebase
|
||||||
|
git config pull.rebase false
|
||||||
|
git config commit.gpgsign true
|
||||||
|
git pull origin master
|
||||||
|
git add . --all
|
||||||
|
git commit -a -S --author="${1} <${2}>" -m "${3}"
|
||||||
|
git push -u origin master
|
||||||
|
else
|
||||||
|
echo "USAGE: ${0} '<full name>' <email address> '<git commit comments>'"
|
||||||
|
fi
|
18
init.lua
18
init.lua
|
@ -41,6 +41,24 @@ P.S. You can delete this when you're done too. It's your config now :)
|
||||||
vim.g.mapleader = ' '
|
vim.g.mapleader = ' '
|
||||||
vim.g.maplocalleader = ' '
|
vim.g.maplocalleader = ' '
|
||||||
|
|
||||||
|
vim.g.copilot_no_tab_map = true
|
||||||
|
vim.api.nvim_set_keymap("i", "<C-J>", 'copilot#Accept("<CR>")', { silent = true, expr = true })
|
||||||
|
vim.api.nvim_set_keymap("i", "<C-H>", 'copilot#Previous()', { silent = true, expr = true })
|
||||||
|
vim.api.nvim_set_keymap("i", "<C-K>", 'copilot#Next()', { silent = true, expr = true })
|
||||||
|
vim.g.copilot_filetypes = {
|
||||||
|
["*"] = false,
|
||||||
|
["c"] = true,
|
||||||
|
["c++"] = true,
|
||||||
|
["go"] = true,
|
||||||
|
["javascript"] = true,
|
||||||
|
["typescript"] = true,
|
||||||
|
["java"] = true,
|
||||||
|
["lua"] = false,
|
||||||
|
["ruby"] = true,
|
||||||
|
["rust"] = true,
|
||||||
|
["python"] = true,
|
||||||
|
}
|
||||||
|
|
||||||
-- Install package manager
|
-- Install package manager
|
||||||
-- https://github.com/folke/lazy.nvim
|
-- https://github.com/folke/lazy.nvim
|
||||||
-- `:help lazy.nvim.txt` for more info
|
-- `:help lazy.nvim.txt` for more info
|
||||||
|
|
Loading…
Reference in New Issue