We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
flake.lock
1 parent b7ca8f6 commit 68202feCopy full SHA for 68202fe
modules/hooks.nix
@@ -692,6 +692,26 @@ in
692
entry = "${tools.nixpkgs-fmt}/bin/nixpkgs-fmt";
693
files = "\\.nix$";
694
};
695
+ nix-flake-lock =
696
+ {
697
+ name = "nix-flake-lock";
698
+ description = "Check that flake.lock is up to date";
699
+ types = [ "file" ];
700
+ pass_filenames = false;
701
+ files = "flake.*$";
702
+ entry = lib.getExe (pkgs.writeShellApplication {
703
704
+ text = ''
705
+ echo "Checking that flake.lock is up to date"
706
+ if nix flake lock --no-update-lock-file; then
707
+ echo "flake.lock is up to date"
708
+ else
709
+ echo "flake.lock is not up to date. Run 'nix flake lock' to update it."
710
+ exit 1
711
+ fi
712
+ '';
713
+ });
714
+ };
715
statix =
716
{
717
name = "statix";
0 commit comments