From dfe41fe593193c84d275550d7eb08ec5ead1bc71 Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 28 Jun 2026 12:00:53 +0000 Subject: [PATCH] bootstrap.sh: fix BASH_SOURCE unbound variable when piped through bash set -euo pipefail causes ${BASH_SOURCE[0]} to abort with 'unbound variable' when the script is fed via curl | bash. Use ${BASH_SOURCE[0]:-} so the variable expands to an empty string in that context, letting SCRIPT_DIR resolve safely and the pipe path continue to the git-clone branch. Co-Authored-By: Claude Sonnet 4.6 Claude-Session: https://claude.ai/code/session_01LQJBvqzXeyuhhAcAA3Q5Wq --- bootstrap.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bootstrap.sh b/bootstrap.sh index af9e050..2f5bac9 100755 --- a/bootstrap.sh +++ b/bootstrap.sh @@ -48,7 +48,7 @@ echo "" # ── Option 3: already running from inside the repo ─────────────────────────── # If setup.sh is sitting next to this script, we have everything we need. -SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" 2>/dev/null && pwd || echo "")" +SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]:-}")" 2>/dev/null && pwd || echo "")" if [ -f "${SCRIPT_DIR}/setup.sh" ]; then echo " Running from local copy at $SCRIPT_DIR" echo " (No git or internet needed)"