diff options
author | Anna (navi) Figueiredo Gomes <navi@vlhl.dev> | 2023-06-28 13:19:22 -0300 |
---|---|---|
committer | Anna (navi) Figueiredo Gomes <navi@vlhl.dev> | 2023-06-28 13:22:02 -0300 |
commit | 8aa44a9d090eb2bd94d358083ea31aca5f16b3ab (patch) | |
tree | ee1a433e2df6da98d6aa57bb03c3d9b38ca242f2 /.config/nvim/lua | |
parent | 6b2523b49746daaa2341ae6d16ca036df56cf548 (diff) |
update
Signed-off-by: Anna (navi) Figueiredo Gomes <navi@vlhl.dev>
Diffstat (limited to '.config/nvim/lua')
-rw-r--r-- | .config/nvim/lua/options.lua | 2 | ||||
-rw-r--r-- | .config/nvim/lua/plugins.lua | 24 |
2 files changed, 20 insertions, 6 deletions
diff --git a/.config/nvim/lua/options.lua b/.config/nvim/lua/options.lua index 8be12cf..afbcb0c 100644 --- a/.config/nvim/lua/options.lua +++ b/.config/nvim/lua/options.lua @@ -6,7 +6,7 @@ vim.opt.path = '.,,**' vim.opt.splitbelow = true vim.opt.splitright = true vim.opt.number = true -vim.opt.relativenumber = false +vim.opt.relativenumber = true vim.opt.cursorline = true vim.opt.autoindent = true diff --git a/.config/nvim/lua/plugins.lua b/.config/nvim/lua/plugins.lua index e956ae4..b5d66ce 100644 --- a/.config/nvim/lua/plugins.lua +++ b/.config/nvim/lua/plugins.lua @@ -44,7 +44,7 @@ return require('packer').startup(function(use) local opts = {noremap = true, silent = true} vim.keymap.set('n', '<leader>f', require('fzf-lua').files, opts) vim.keymap.set('n', '<leader>b', require('fzf-lua').buffers, opts) - vim.keymap.set('n', '<leader>Q', require('fzf-lua').quick_fix, opts) + vim.keymap.set('n', '<leader>Q', require('fzf-lua').quickfix, opts) vim.keymap.set('n', '<leader>t', require('fzf-lua').tabs, opts) end } @@ -104,6 +104,16 @@ return require('packer').startup(function(use) capabilities = capabilities } + lspconfig.pylsp.setup { + on_attach = on_attach, + capabilities = capabilities + } + + lspconfig.tsserver.setup { + on_attach = on_attach, + capabilities = capabilities + } + lspconfig.lua_ls.setup { on_attach = on_attach, capabilities = capabilities, @@ -191,17 +201,15 @@ return require('packer').startup(function(use) ['<S-Tab>'] = cmp.mapping(function(fallback) if cmp.visible() then cmp.select_prev_item() - elseif luasnip.jumpable(-1) then + elseif luasnip.locally_jumpable(-1) then luasnip.jump(-1) else fallback() end end, { "i", "s" }), - ['<C-n>'] = cmp.mapping(function(fallback) + ['<C-n>'] = cmp.mapping(function() if luasnip.choice_active() then luasnip.change_choice(1) - else - fallback() end end), }), @@ -210,6 +218,12 @@ return require('packer').startup(function(use) { name = 'luasnip' }, { name = 'nvim_lsp_signature_help' } }), + formatting = { + format = function(_, vim_item) + vim_item.abbr = string.sub(vim_item.abbr, 1, 80) + return vim_item + end + } }) cmp.setup.cmdline({ '/', '?' }, { sources = cmp.config.sources({ |