fix(commands): Phase 0 gives the arguments to the parser on stdin, never as shell words
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
f1704f0800
commit
2c0a98c1ba
8 changed files with 157 additions and 29 deletions
|
|
@ -72,9 +72,12 @@ Execute these phases in order. Do not skip phases.
|
|||
|
||||
### Phase 1 — Parse mode and validate input
|
||||
|
||||
Run the arg-parser via Bash:
|
||||
Run the arg-parser via Bash, with the arguments as the one line inside the
|
||||
quoted heredoc (on stdin, never as shell words):
|
||||
```
|
||||
node ${CLAUDE_PLUGIN_ROOT}/lib/parsers/arg-parser.mjs --command trekreview -- "$@"
|
||||
node ${CLAUDE_PLUGIN_ROOT}/lib/parsers/arg-parser.mjs --command trekreview --stdin <<'VOYAGE_ARGS_EOF_7F3C9E'
|
||||
$ARGUMENTS
|
||||
VOYAGE_ARGS_EOF_7F3C9E
|
||||
```
|
||||
|
||||
Pull the structured flags from its JSON output. Reject unknown flags. If
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue