fix(cli): keep SLUG accessible to cleanup_all EXIT trap

cmd_start declared SLUG as local, but cleanup_all (registered as the
EXIT/INT/TERM trap) calls pipelock_stop "$SLUG" after cmd_start has
returned and the local is out of scope. With set -u this aborted
shell teardown with "SLUG: unbound variable". Drop the local to
match the convention already used for MANIFEST_FILE, CONTAINER, and
STAGE_DIR.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
2026-05-08 02:06:17 -04:00
parent ba7616a4ae
commit 400e914f1f
+1 -1
View File
@@ -285,7 +285,7 @@ cmd_start() {
exit 2
fi
local SLUG
# Not declared local: needed by cleanup_all after cmd_start returns (see MANIFEST_FILE note below).
SLUG="$(slugify "$NAME")"
local IMAGE="${CLAUDE_BOTTLE_IMAGE:-claude-bottle:latest}"