diff options
Diffstat (limited to 'dev.nix')
| -rw-r--r-- | dev.nix | 44 |
1 files changed, 44 insertions, 0 deletions
@@ -0,0 +1,44 @@ +{ + lib, + inputs, + ... +}: { + imports = [ + inputs.pre-commit.flakeModule + ]; + + perSystem = { + pkgs, + config, + inputs', + ... + }: { + pre-commit = { + settings.hooks = { + actionlint.enable = true; + alejandra.enable = true; + deadnix.enable = true; + nil.enable = true; + statix.enable = true; + }; + }; + + devShells = { + default = pkgs.mkShell { + shellHook = config.pre-commit.installationScript; + packages = with pkgs; + [ + actionlint + alejandra + deadnix + just + nil + statix + ] + ++ lib.optional stdenv.isLinux inputs'.agenix.packages.agenix; + }; + }; + + formatter = pkgs.alejandra; + }; +} |
