aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/dot_config/nvim/lua/plugins/lsp.lua
diff options
context:
space:
mode:
authorLibravatar sommerfeld <sommerfeld@sommerfeld.dev>2026-05-20 13:56:09 +0100
committerLibravatar sommerfeld <sommerfeld@sommerfeld.dev>2026-05-20 13:56:09 +0100
commit2d9ed00606be2f8c63aba719d00adf70fe6d4393 (patch)
tree013dd78dcb1b316b69286b883e3f8dfad94ac142 /dot_config/nvim/lua/plugins/lsp.lua
parente66aa35ea314f522a2cdfaebdacf87894a44bd04 (diff)
downloaddotfiles-2d9ed00606be2f8c63aba719d00adf70fe6d4393.tar.gz
dotfiles-2d9ed00606be2f8c63aba719d00adf70fe6d4393.tar.bz2
dotfiles-2d9ed00606be2f8c63aba719d00adf70fe6d4393.zip
refactor(nvim,zsh): remove Mason; use Home-Manager-provisioned tooling
LSPs, formatters, linters, and the lldb-dap debugger now come from ~/.nix-profile/bin (see nix/common.nix). lspconfig keeps the default configs; we just opt-in via vim.lsp.enable() with an explicit list. Changes: - dot_config/nvim/lua/plugins/lsp.lua: drop mason*, replace mason-lspconfig handler with explicit vim.lsp.enable({...}); drop groovy/jenkins formatters and lint entries; drop systemd lint (nginx + groovy + systemdlint tools dropped per plan). - dot_config/nvim/lua/plugins/debug.lua: drop mason-nvim-dap; drop codelldb adapter; switch dap.configurations.cpp to type='lldb' (lldb-dap is the upstream successor, ships with pkgs.lldb). - dot_config/nvim/init.lua: remove mason.nvim, mason-lspconfig.nvim, mason-tool-installer.nvim, mason-nvim-dap.nvim from vim.pack.add. - dot_config/nvim/lua/config/update.lua: remove MasonToolsUpdateSync. - dot_config/zsh/dot_zshrc: flip plugin source order — prefer ~/.nix-profile/share, fall back to /usr/share/zsh (was the other way around). - nix/bootstrap.sh: drop the uv-python3.11 step (no longer needed once Mason no longer source-builds Python LSPs on Ubuntu 20.04). Phase 6 of the nix-on-host migration plan.
Diffstat (limited to 'dot_config/nvim/lua/plugins/lsp.lua')
-rw-r--r--dot_config/nvim/lua/plugins/lsp.lua89
1 files changed, 24 insertions, 65 deletions
diff --git a/dot_config/nvim/lua/plugins/lsp.lua b/dot_config/nvim/lua/plugins/lsp.lua
index a2a4036..5039d04 100644
--- a/dot_config/nvim/lua/plugins/lsp.lua
+++ b/dot_config/nvim/lua/plugins/lsp.lua
@@ -8,66 +8,30 @@ vim.lsp.enable("just")
pcall(vim.lsp.enable, "tblgen_lsp_server")
require("fidget").setup({})
-require("mason").setup({})
-require("mason-lspconfig").setup({
- ensure_installed = {},
- automatic_installation = false,
- handlers = {
- function(server_name)
- vim.lsp.enable(server_name)
- end,
- },
-})
-require("mason-tool-installer").setup({
- ensure_installed = {
- "actionlint",
- "autotools-language-server",
- -- basedpyright: provided by the system pkg manager (basedpyright-bin from
- -- AUR on Arch, pkgs.basedpyright in remote-dev/home.nix on the VM). Mason's pypi
- -- distro pulls `nodejs-wheel-binaries` whose Linux wheels are only
- -- manylinux_2_28; uv's standalone python (manylinux2014) rejects them and
- -- pip falls back to building Node from source, which fails on Ubuntu
- -- 20.04's gcc 9.4 (<10, no -std=gnu++20). lspconfig finds it on PATH.
- "bash-language-server",
- "clangd",
- "codelldb",
- "codespell",
- "css-lsp",
- "dockerfile-language-server",
- "gh",
- "gh-actions-language-server",
- "groovy-language-server",
- "hadolint",
- "html-lsp",
- "jq",
- "json-lsp",
- "jsonlint",
- "just-lsp",
- "lua-language-server",
- "markdownlint",
- "mdformat",
- "neocmakelsp",
- "nginx-config-formatter",
- "nginx-language-server",
- "npm-groovy-lint",
- "prettier",
- "ruff",
- "rust-analyzer",
- "selene",
- "shellcheck",
- "shellharden",
- "shfmt",
- "stylelint",
- "stylua",
- "systemd-lsp",
- "systemdlint",
- "taplo",
- "typescript-language-server",
- "typos",
- "yaml-language-server",
- "yamllint",
- "yq",
- },
+
+-- LSPs come from Home-Manager (see nix/common.nix). lspconfig ships the
+-- default configs; we just opt-in per server. (Previously this was driven
+-- by mason-lspconfig handlers; phase p6 of the nix migration removed
+-- Mason entirely.)
+vim.lsp.enable({
+ "autotools_ls",
+ "basedpyright",
+ "bashls",
+ "clangd",
+ "cssls",
+ "dockerls",
+ "eslint",
+ "gh_actions_ls",
+ "html",
+ "jsonls",
+ "lua_ls",
+ "neocmake",
+ "ruff",
+ "rust_analyzer",
+ "systemd_ls",
+ "taplo",
+ "ts_ls",
+ "yamlls",
})
vim.api.nvim_create_autocmd("LspAttach", {
@@ -194,11 +158,9 @@ require("conform").setup({
bash = { "shfmt" },
cmake = { "cmake_format" },
css = { "prettier", "stylelint" },
- groovy = { "npm-groovy-lint" },
html = { "prettier" },
javascript = { "prettier" },
typescript = { "prettier" },
- jenkins = { "npm-groovy-lint" },
json = { "jq", "jsonlint" },
jsonc = { "prettier" },
just = { "just" },
@@ -230,12 +192,9 @@ local lint = require("lint")
lint.linters_by_ft = {
css = { "stylelint" },
dockerfile = { "hadolint" },
- groovy = { "npm-groovy-lint" },
- jenkins = { "npm-groovy-lint" },
json = { "jsonlint" },
markdown = { "markdownlint" },
makefile = { "checkmake" },
- systemd = { "systemdlint" },
yaml = { "yamllint", "yq" },
ghaction = { "actionlint" },
zsh = { "zsh" },