diff --git a/release.nix b/release.nix
index 5a5a1226fe2c88e550e3ea08864c7380871776f0..dd5f1c4d37bca36c5e7a00750ed5e5dd0f6e7812 100644
--- a/release.nix
+++ b/release.nix
@@ -36,7 +36,7 @@ let
 
         postUnpack = ''
           # Clean up when building from a working tree.
-          (cd $sourceRoot && (git ls-files -o | xargs -r rm -v))
+          git -C $sourceRoot clean -fd
         '';
 
         preConfigure = ''