1
0
Fork 0
mirror of https://github.com/nix-community/home-manager.git synced 2025-11-08 19:46:05 +01:00

format: Fix failing due to no cache access

We change `$HOME` to something not writable, but newer treefmt fails if
it cannot write. We could use a tmpdir, but there’s not much point to a
cache that will be removed, as just add the flag to not use the cache.
This commit is contained in:
Andrew Marshall 2025-04-24 13:46:15 -04:00 committed by Austin Horstman
parent dedfde15f6
commit 98f4fef7fd

2
format
View file

@ -32,4 +32,4 @@ git_root=$(git rev-parse --show-toplevel)
git ls-files -z --cached --others --full-name -- "${files[@]}" |
grep -z '\.nix$' |
sed -z "s|^|$git_root/|" |
xargs -0 treefmt "${nixfmt_args[@]}"
xargs -0 treefmt --no-cache "${nixfmt_args[@]}"