aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/dot_config
diff options
context:
space:
mode:
authorLibravatar sommerfeld <sommerfeld@sommerfeld.dev>2026-05-14 11:43:18 +0100
committerLibravatar sommerfeld <sommerfeld@sommerfeld.dev>2026-05-14 11:43:18 +0100
commite564f01583cbc9e9182bfe3ceca734e8680d8d2f (patch)
treee53c954a5edd8cc8dc9843e3223e40c60bca4d72 /dot_config
parent0a0d087b2125b6c7b6461d58f57265bc56b3b22b (diff)
downloaddotfiles-e564f01583cbc9e9182bfe3ceca734e8680d8d2f.tar.gz
dotfiles-e564f01583cbc9e9182bfe3ceca734e8680d8d2f.tar.bz2
dotfiles-e564f01583cbc9e9182bfe3ceca734e8680d8d2f.zip
revert(nvim)+fix(remote-dev): keep Mason authoritative, give it cargo+rustc
User policy: Mason should install everything it lists regardless of host-provided versions. Revert the PATH-filtering wrapper around ensure_installed (b2f129e) — back to a plain table literal. For shellharden specifically, Mason's only install source is `cargo install`. The Arch host has cargo via base-devel/rustup; the VM previously didn't, so Mason errored "ENOENT cargo". Add `cargo` and `rustc` to the remote-dev nix profile so Mason can build it on the VM too. Drop the shellharden package from home.nix — Mason owns it now, no more provider competition with the nix-profile binary.
Diffstat (limited to 'dot_config')
-rw-r--r--dot_config/nvim/lua/plugins/lsp.lua101
1 files changed, 44 insertions, 57 deletions
diff --git a/dot_config/nvim/lua/plugins/lsp.lua b/dot_config/nvim/lua/plugins/lsp.lua
index 69f8163..1a115db 100644
--- a/dot_config/nvim/lua/plugins/lsp.lua
+++ b/dot_config/nvim/lua/plugins/lsp.lua
@@ -19,63 +19,50 @@ require("mason-lspconfig").setup({
},
})
require("mason-tool-installer").setup({
- ensure_installed = (function()
- local tools = {
- "actionlint",
- "autotools-language-server",
- "basedpyright",
- "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",
- }
- -- Skip Mason install when the tool is already on PATH from the system
- -- (e.g. shellharden via nix-profile on the remote-dev VM, where Mason's
- -- cargo-build install path would fail). Mason's runners still discover
- -- PATH binaries, so conform.nvim/nvim-lint keep working.
- local filtered = {}
- for _, name in ipairs(tools) do
- if vim.fn.executable(name) ~= 1 then
- table.insert(filtered, name)
- end
- end
- return filtered
- end)(),
+ ensure_installed = {
+ "actionlint",
+ "autotools-language-server",
+ "basedpyright",
+ "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",
+ },
})
vim.api.nvim_create_autocmd("LspAttach", {