nvim: Add texlab LSP; Clean up ruff config

This commit is contained in:
Andreas Tsouchlos 2025-06-26 10:30:30 -04:00
parent d95aefb166
commit c8a8f61a9f
2 changed files with 28 additions and 23 deletions

View File

@ -1,23 +1,3 @@
-- return {
-- cmd = {
-- 'pyright-langserver', '--stdio'
-- },
-- settings = {
-- python = {
-- analysis = {
-- typeCheckingMode = "basic", -- or "strict", "off"
-- autoSearchPaths = true,
-- useLibraryCodeForTypes = true,
-- },
-- },
-- },
-- root_markers = {
-- 'pyproject.toml', 'setup.py', 'setup.cfg', 'requirements.txt', '.git'
-- },
-- filetypes = {
-- 'python'
-- },
-- }
return {
cmd = {
'ruff', 'server'
@ -27,7 +7,5 @@ return {
},
root_markers = {
'setup.py', 'setup.cfg', 'requirements.txt', '.git', 'ruff.toml'
},
-- single_file_support = true,
-- settings = {},
}
}

View File

@ -0,0 +1,27 @@
return {
cmd = { 'texlab' },
filetypes = { 'tex' },
root_markers = { '.git', '.latexmkrc' },
settings = {
texlab = {
rootDirectory = nil,
build = {
executable = 'latexmk',
args = { '-pdf', '-interaction=nonstopmode', '-synctex=1', '%f' },
onSave = false,
forwardSearchAfter = false,
},
forwardSearch = {
executable = nil,
args = {},
},
chktex = {
onOpenAndSave = false,
onEdit = false,
},
diagnosticsDelay = 300,
latexFormatter = 'tex-fmt',
bibtexFormatter = 'tex-fmt',
},
},
}