From 1dd5df3d8beb9cac7f8256bbf5db71b85c7a3d55 Mon Sep 17 00:00:00 2001 From: Pierre Kisters <1524059+lhns@users.noreply.github.com> Date: Thu, 1 Oct 2026 04:08:23 +0200 Subject: [PATCH] Install: a long list of untracked files doesn't abort the install With pipefail, head closing the pipe early made git's SIGPIPE fail the assignment under set -e. --- install.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/install.sh b/install.sh index a0d9ce5..8d8825e 100755 --- a/install.sh +++ b/install.sh @@ -345,7 +345,8 @@ cmd_install() { if [[ -n $dir ]] && git -C "$dir" rev-parse --is-inside-work-tree >/dev/null 2>&1; then local untracked - untracked="$(git -C "$dir" ls-files --others --exclude-standard -- '*.nix' | head -n5)" + # || true: with pipefail, head closing the pipe early fails git. + untracked="$(git -C "$dir" ls-files --others --exclude-standard -- '*.nix' | head -n5 || true)" [[ -z $untracked ]] || warn "untracked files are invisible to the flake (git add them): $(echo "$untracked" | tr '\n' ' ')" fi