Skip to content

Fix merge script returning exit 1 on successful merge#234

Merged
drn merged 1 commit intomasterfrom
worktree-argus/handoff-improve-merge-script
Mar 15, 2026
Merged

Fix merge script returning exit 1 on successful merge#234
drn merged 1 commit intomasterfrom
worktree-argus/handoff-improve-merge-script

Conversation

@drn
Copy link
Owner

@drn drn commented Mar 15, 2026

Replace [[ ]] && pattern in print_summary with if/then to prevent empty optional variables from leaking exit code 1 as the script's final status.

Co-Authored-By: Claude noreply@anthropic.com

The print_summary function used `[[ -n "$VAR" ]] && echo` for optional
output lines. When the variable was empty, the `[[ ]]` returned 1 and
short-circuited — making 1 the script's exit code despite success.
Replaced with if/then to avoid leaking exit codes.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@drn drn merged commit 7013ad8 into master Mar 15, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant