vim to neovim

This commit is contained in:
2024-08-23 11:20:30 +02:00
parent 64e3e458bc
commit 3808dc2b23
26 changed files with 430 additions and 30 deletions

View File

@ -0,0 +1,5 @@
vim.lsp.start({
name = 'clangd',
cmd = {'clangd'},
-- root_dir = vim.fs.root(args.buf, {'Makefile'})
})

View File

@ -0,0 +1,4 @@
vim.lsp.start({
name = 'lua-language-server',
cmd = {'lua-language-server'},
})

View File

@ -0,0 +1,4 @@
vim.lsp.start({
name = 'jedi',
cmd = {'jedi-language-server'},
})

View File

@ -0,0 +1,4 @@
vim.lsp.start({
name = 'texlab',
cmd = {'texlab'},
})

View File

@ -0,0 +1,3 @@
set runtimepath^=~/.vim runtimepath+=~/.vim/after
let &packpath = &runtimepath
source ~/.vimrc

View File

@ -0,0 +1 @@
vim.g.vimtex_view_method="zathura"

View File

@ -0,0 +1,24 @@
--- Default maps for LSP functions.
---
--- These are mapped unconditionally to avoid different behavior depending on whether an LSP
--- client is attached. If no client is attached, or if a server does not support a capability, an
--- error message is displayed rather than exhibiting different behavior.
---
--- See |grr|, |grn|, |gra|, |i_CTRL-S|.
do
vim.keymap.set('n', 'grn', function()
vim.lsp.buf.rename()
end, { desc = 'vim.lsp.buf.rename()' })
vim.keymap.set({ 'n', 'x' }, 'gra', function()
vim.lsp.buf.code_action()
end, { desc = 'vim.lsp.buf.code_action()' })
vim.keymap.set('n', 'grr', function()
vim.lsp.buf.references()
end, { desc = 'vim.lsp.buf.references()' })
vim.keymap.set('i', '<C-S>', function()
vim.lsp.buf.signature_help()
end, { desc = 'vim.lsp.buf.signature_help()' })
end