From fd59dd0d6591619a751a3d01a71e3eb2d17b8f60 Mon Sep 17 00:00:00 2001 From: Price Hiller Date: Thu, 7 Mar 2024 15:51:18 -0600 Subject: [PATCH] refactor(nvim): replace `nixd` with `nil_ls` --- dots/.config/nvim/lua/plugins/configs/lsp.lua | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/dots/.config/nvim/lua/plugins/configs/lsp.lua b/dots/.config/nvim/lua/plugins/configs/lsp.lua index 4beb5025..f1206a6d 100644 --- a/dots/.config/nvim/lua/plugins/configs/lsp.lua +++ b/dots/.config/nvim/lua/plugins/configs/lsp.lua @@ -466,9 +466,25 @@ return { dap_debug_gui = true, }) + lspconfig.nil_ls.setup({ + capabilities = lsp_capabilities, + on_attach = on_attach, + settings = { + ["nil"] = { + formatting = { command = { "nixfmt" } }, + nix = { + maxMemoryMB = 60000, + flake = { + autoArchive = true, + autoEvalInputs = true + } + } + }, + }, + }) + -- NOTE: GENERIC LSP SERVERS for _, server in ipairs({ - "nixd", "clangd", "cmake", "bashls",