From b107437e21689e002762cbba76f64945ff784b0c Mon Sep 17 00:00:00 2001 From: Sakooooo <78461130+Sakooooo@users.noreply.github.com> Date: Sun, 6 Aug 2023 11:48:01 +0300 Subject: [PATCH] add nixpkgs-fmt --- config/nvim/lua/core/plugin_config/lsp_config.lua | 8 ++++++++ modules/dev/nil.nix | 1 + packages/.nixd.json | 10 ---------- 3 files changed, 9 insertions(+), 10 deletions(-) delete mode 100644 packages/.nixd.json diff --git a/config/nvim/lua/core/plugin_config/lsp_config.lua b/config/nvim/lua/core/plugin_config/lsp_config.lua index 04c17406..3b225c43 100644 --- a/config/nvim/lua/core/plugin_config/lsp_config.lua +++ b/config/nvim/lua/core/plugin_config/lsp_config.lua @@ -33,6 +33,14 @@ mason_null_ls.setup() require('lspconfig').nil_ls.setup({ on_attach = on_attach, capabilities = capabilities, + settings = { + ['nil'] = { + testSetting = 42, + formatting = { + command = { "nixpkgs-fmt" }, + }, + }, + }, }) diff --git a/modules/dev/nil.nix b/modules/dev/nil.nix index a4152cbb..4f6d3f4f 100644 --- a/modules/dev/nil.nix +++ b/modules/dev/nil.nix @@ -11,6 +11,7 @@ in config = mkIf cfg.enable { environment.systemPackages = with pkgs; [ nil + nixpkgs-fmt ]; }; } diff --git a/packages/.nixd.json b/packages/.nixd.json deleted file mode 100644 index 9cc5cfb6..00000000 --- a/packages/.nixd.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "eval": { - "target": { - "args": [ - "--expr", - "with import { }; callPackage ./nullpomino.nix { }" - ] - } - } -}