fix: replace echo with printf in shell snippets to prevent jq parse errors

zsh's built-in echo interprets \n escape sequences in JSON strings,
converting properly-escaped \\n back into literal newlines. This breaks
jq parsing with "control characters U+0000 through U+001F must be escaped".
printf '%s\n' preserves the JSON verbatim.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Lex Christopherson
2026-03-02 12:07:45 -06:00
parent 1c58e84eb3
commit 4010e3ff0e
4 changed files with 11 additions and 11 deletions

View File

@@ -66,7 +66,7 @@ Find highest existing phase:
```bash
# Get sorted phase list, extract last one
PHASES=$(node "$HOME/.claude/get-shit-done/bin/gsd-tools.cjs" phases list)
HIGHEST=$(echo "$PHASES" | jq -r '.directories[-1]')
HIGHEST=$(printf '%s\n' "$PHASES" | jq -r '.directories[-1]')
```
New phases continue from there: