mirror of
https://codeberg.org/leana8959/.files.git
synced 2025-12-06 06:39:14 +00:00
pre-commit devShell
This commit is contained in:
parent
817986b317
commit
28c9634485
4 changed files with 118 additions and 5 deletions
19
nix/pre-commit/default.nix
Normal file
19
nix/pre-commit/default.nix
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
{ inputs, ... }:
|
||||
{
|
||||
imports = [ inputs.pre-commit-hooks.flakeModule ];
|
||||
perSystem =
|
||||
{ pkgs, config, ... }:
|
||||
{
|
||||
pre-commit = {
|
||||
check.enable = true;
|
||||
settings.hooks = {
|
||||
nixfmt.enable = true;
|
||||
nixfmt.package = pkgs.nixfmt-rfc-style;
|
||||
# statix.enable = true; # FIXME: seems to loop
|
||||
deadnix.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
devShells.default = pkgs.mkShell { shellHook = config.pre-commit.installationScript; };
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue