From e7d9abfdcdc49ef6f9f28443ec48bce307fdb0a2 Mon Sep 17 00:00:00 2001 From: Timothy DeHerrera Date: Mon, 1 Feb 2021 14:05:53 -0700 Subject: [PATCH] shell: fix pre-commit on deleted files --- shell/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shell/default.nix b/shell/default.nix index 038ca2d..770d2f6 100644 --- a/shell/default.nix +++ b/shell/default.nix @@ -69,7 +69,7 @@ pkgs.devshell.mkShell { # Format staged nix files. exec ${nixpkgs-fmt}/bin/nixpkgs-fmt \ $( - ${git}/bin/git diff-index --name-only --cached $against -- \ + ${git}/bin/git diff-index --name-only --cached $against --diff-filter d -- \ | ${ripgrep}/bin/rg '\.nix$' ) '';