diff --git a/ftplugin/javascript.lua b/ftplugin/javascript.lua index ed7f6bb9..8eaf4ae4 100644 --- a/ftplugin/javascript.lua +++ b/ftplugin/javascript.lua @@ -1,3 +1,3 @@ -vim.opt.tabstop = 2 -vim.opt.softtabstop = 2 -vim.opt.shiftwidth = 2 +vim.opt.tabstop = 4 +vim.opt.softtabstop = 4 +vim.opt.shiftwidth = 4 diff --git a/ftplugin/typescript.lua b/ftplugin/typescript.lua index ed7f6bb9..8eaf4ae4 100644 --- a/ftplugin/typescript.lua +++ b/ftplugin/typescript.lua @@ -1,3 +1,3 @@ -vim.opt.tabstop = 2 -vim.opt.softtabstop = 2 -vim.opt.shiftwidth = 2 +vim.opt.tabstop = 4 +vim.opt.softtabstop = 4 +vim.opt.shiftwidth = 4 diff --git a/init.lua b/init.lua index 2ed8d188..9398e4c4 100644 --- a/init.lua +++ b/init.lua @@ -533,8 +533,9 @@ require('lazy').setup({ local servers = { -- clangd = {}, -- gopls = {}, - -- pyright = {}, + pyright = {}, -- rust_analyzer = {}, + -- java_language_server = {}, -- ... etc. See `:help lspconfig-all` for a list of all the pre-configured LSPs -- -- Some languages (like typescript) have entire language plugins that can be useful: @@ -684,7 +685,7 @@ require('lazy').setup({ -- No, but seriously. Please read `:help ins-completion`, it is really good! mapping = cmp.mapping.preset.insert { -- Select the [n]ext item - [''] = cmp.mapping.select_next_item(), + [''] = cmp.mapping.select_next_item(), -- Select the [p]revious item [''] = cmp.mapping.select_prev_item(), @@ -695,7 +696,7 @@ require('lazy').setup({ -- Accept ([y]es) the completion. -- This will auto-import if your LSP supports it. -- This will expand snippets if the LSP sent a snippet. - [''] = cmp.mapping.confirm { select = true }, + [''] = cmp.mapping.confirm { select = true }, -- If you prefer more traditional completion keymaps, -- you can uncomment the following lines diff --git a/lua/plugins/copilot.lua b/lua/plugins/copilot.lua index 9567ee49..bd703ed8 100644 --- a/lua/plugins/copilot.lua +++ b/lua/plugins/copilot.lua @@ -3,6 +3,14 @@ return { cmd = 'Copilot', event = 'InsertEnter', config = function() - require('copilot').setup {} + require('copilot').setup { + suggestion = { + keymap = { + accept = '', + next = '', + }, + }, + } + require('copilot.suggestion').toggle_auto_trigger() end, }