diff options
author | Alan Pearce | 2024-05-04 12:38:32 +0200 |
---|---|---|
committer | Alan Pearce | 2024-05-04 14:49:08 +0200 |
commit | df2a55f82d5efeed8c59c5cf3b4e7381c97959b5 (patch) | |
tree | db5fe1e53a4317fa8d35ef9596a082ac20fe70de /default.nix | |
parent | 1fb64b09e2dba34784732a61cbebc119cd847803 (diff) | |
download | searchix-df2a55f82d5efeed8c59c5cf3b4e7381c97959b5.tar.lz searchix-df2a55f82d5efeed8c59c5cf3b4e7381c97959b5.tar.zst searchix-df2a55f82d5efeed8c59c5cf3b4e7381c97959b5.zip |
chore: use prettier with plugin to format go templates
Diffstat (limited to 'default.nix')
-rw-r--r-- | default.nix | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/default.nix b/default.nix index 3db0a44..d3585e0 100644 --- a/default.nix +++ b/default.nix @@ -5,6 +5,7 @@ in import sources.nixpkgs { overlays = [ (import "${sources.gomod2nix}/overlay.nix") + (import ./nix/overlays/default.nix) ]; } ) @@ -33,12 +34,18 @@ in golangci-lint.enable = true; staticcheck.enable = true; - statix.enable = true; + statix = { + enable = true; + settings.ignore = [ "nix/*" ]; + }; deadnix = { enable = true; - excludes = [ "./nix" ]; + excludes = [ "nix/.*" ]; + }; + nixpkgs-fmt = { + enable = true; + excludes = [ "nix/.*" ]; }; - nixpkgs-fmt.enable = true; convco.enable = true; @@ -47,9 +54,11 @@ in editorconfig-checker.enable = true; prettier = { enable = true; - types_or = [ "plain-text" "yaml" ]; + types_or = [ "plain-text" "yaml" "gotmpl" ]; settings = { - check = true; + plugins = with pkgs.nodePackages; [ + "${prettier-plugin-go-template}/lib/node_modules/prettier-plugin-go-template/lib/index.js" + ]; }; }; |