vim to neovim
This commit is contained in:
5
nvim/.config/nvim/after/ftplugin/c.lua
Normal file
5
nvim/.config/nvim/after/ftplugin/c.lua
Normal file
@ -0,0 +1,5 @@
|
||||
vim.lsp.start({
|
||||
name = 'clangd',
|
||||
cmd = {'clangd'},
|
||||
-- root_dir = vim.fs.root(args.buf, {'Makefile'})
|
||||
})
|
4
nvim/.config/nvim/after/ftplugin/lua.lua
Normal file
4
nvim/.config/nvim/after/ftplugin/lua.lua
Normal file
@ -0,0 +1,4 @@
|
||||
vim.lsp.start({
|
||||
name = 'lua-language-server',
|
||||
cmd = {'lua-language-server'},
|
||||
})
|
4
nvim/.config/nvim/after/ftplugin/python.lua
Normal file
4
nvim/.config/nvim/after/ftplugin/python.lua
Normal file
@ -0,0 +1,4 @@
|
||||
vim.lsp.start({
|
||||
name = 'jedi',
|
||||
cmd = {'jedi-language-server'},
|
||||
})
|
4
nvim/.config/nvim/after/ftplugin/tex.lua
Normal file
4
nvim/.config/nvim/after/ftplugin/tex.lua
Normal file
@ -0,0 +1,4 @@
|
||||
vim.lsp.start({
|
||||
name = 'texlab',
|
||||
cmd = {'texlab'},
|
||||
})
|
3
nvim/.config/nvim/init.vim
Normal file
3
nvim/.config/nvim/init.vim
Normal file
@ -0,0 +1,3 @@
|
||||
set runtimepath^=~/.vim runtimepath+=~/.vim/after
|
||||
let &packpath = &runtimepath
|
||||
source ~/.vimrc
|
1
nvim/.config/nvim/plugin/configs.lua
Normal file
1
nvim/.config/nvim/plugin/configs.lua
Normal file
@ -0,0 +1 @@
|
||||
vim.g.vimtex_view_method="zathura"
|
24
nvim/.config/nvim/plugin/lsp.lua
Normal file
24
nvim/.config/nvim/plugin/lsp.lua
Normal 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
|
Reference in New Issue
Block a user