update
This commit is contained in:
commit
3d6e9d215e
@ -24,7 +24,6 @@
|
||||
"indent-blankline.nvim": { "branch": "master", "commit": "005b56001b2cb30bfa61b7986bc50657816ba4ba" },
|
||||
"lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" },
|
||||
"lazydev.nvim": { "branch": "main", "commit": "2367a6c0a01eb9edb0464731cc0fb61ed9ab9d2c" },
|
||||
"lsp_lines.nvim": { "branch": "main", "commit": "a92c755f182b89ea91bd8a6a2227208026f27b4d" },
|
||||
"lspkind.nvim": { "branch": "master", "commit": "d79a1c3299ad0ef94e255d045bed9fa26025dab6" },
|
||||
"lualine.nvim": { "branch": "master", "commit": "15884cee63a8c205334ab13ab1c891cd4d27101a" },
|
||||
"mcphub.nvim": { "branch": "main", "commit": "81394b54e292a50361aba11198e5fa4ebb97d304" },
|
||||
|
@ -71,3 +71,15 @@ local border = {
|
||||
-- l.handlers["textDocument/signatureHelp"] = vim.lsp.with(vim.lsp.handlers.signature_help, { border = border })
|
||||
-- l.handlers["textDocument/hover"] = vim.lsp.with(vim.lsp.handlers.hover, { border = border })
|
||||
o.winborder = "rounded"
|
||||
|
||||
vim.diagnostic.config({
|
||||
virtual_text = true,
|
||||
signs = true,
|
||||
underline = true,
|
||||
float = { border = "rounded", source = true },
|
||||
severity_sort = true,
|
||||
})
|
||||
vim.keymap.set("", "<Leader>tl", function()
|
||||
local current = vim.diagnostic.config().virtual_text
|
||||
vim.diagnostic.config({ virtual_text = not current })
|
||||
end, { desc = "Toggle diagnostics virtual text" })
|
||||
|
@ -1,9 +0,0 @@
|
||||
return {
|
||||
"https://git.sr.ht/~whynothugo/lsp_lines.nvim",
|
||||
config = function()
|
||||
-- lsp_lines
|
||||
vim.diagnostic.config({ virtual_text = false })
|
||||
-- --
|
||||
vim.keymap.set("", "<Leader>tl", require("lsp_lines").toggle, { desc = "Toggle lsp_lines" })
|
||||
end,
|
||||
}
|
@ -5,7 +5,8 @@ return {
|
||||
vim.notify = require("notify")
|
||||
local servers = {
|
||||
"bashls",
|
||||
"jedi_language_server",
|
||||
-- "jedi_language_server",
|
||||
"basedpyright",
|
||||
"jsonls",
|
||||
-- "yamlls",
|
||||
"vimls",
|
||||
@ -75,6 +76,19 @@ return {
|
||||
},
|
||||
handlers = {},
|
||||
})
|
||||
elseif lsp == "basedpyright" then
|
||||
vim.lsp.enable(lsp)
|
||||
vim.lsp.config(lsp, {
|
||||
analysis = {
|
||||
autoSearchPaths = true,
|
||||
diagnosticMode = "openFilesOnly",
|
||||
useLibraryCodeForTypes = true,
|
||||
},
|
||||
diagnosticMode = "openFilesOnly",
|
||||
inlayHints = {
|
||||
callArgumentNames = true,
|
||||
},
|
||||
})
|
||||
else
|
||||
vim.lsp.enable(lsp)
|
||||
-- vim.lsp.config(lsp, {
|
||||
|
@ -1,7 +1,8 @@
|
||||
return {
|
||||
"mfussenegger/nvim-lint",
|
||||
config = function()
|
||||
require("lint").linters_by_ft = {
|
||||
local lint = require("lint")
|
||||
lint.linters_by_ft = {
|
||||
markdown = { "markdownlint" },
|
||||
lua = { "luacheck" },
|
||||
py = { "flake8", "pylint", "pydocstyle", "pycodestyle", "mypy" },
|
||||
@ -20,5 +21,14 @@ return {
|
||||
"-e",
|
||||
"2250",
|
||||
}
|
||||
local lint_augroup = vim.api.nvim_create_augroup("lint", { clear = true })
|
||||
|
||||
vim.api.nvim_create_autocmd({ "BufEnter", "BufWritePost", "InsertLeave" }, {
|
||||
group = lint_augroup,
|
||||
callback = function()
|
||||
lint.try_lint()
|
||||
end,
|
||||
})
|
||||
end,
|
||||
event = { "BufReadPre", "BufNewFile" },
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user