Skip to content

[codex] support multiline command blocks#5

Closed
brandonbloom wants to merge 1 commit into
mainfrom
codex/multiline-command-blocks
Closed

[codex] support multiline command blocks#5
brandonbloom wants to merge 1 commit into
mainfrom
codex/multiline-command-blocks

Conversation

@brandonbloom

Copy link
Copy Markdown
Member

Summary

  • Accumulate commands until the shell parser reports they are complete.
  • Support heredocs, multiline quoted strings, shell blocks, and multiple heredocs.
  • Add checker/update coverage and docs.

Validation

  • ./test.sh

@claude

claude Bot commented Jul 5, 2026

Copy link
Copy Markdown

Claude encountered an error —— View job


I'll analyze this and get back to you.

@brandonbloom

Copy link
Copy Markdown
Member Author

I recommend closing this design in favor of #6.

The auto-detect approach is elegant and shell-like, but it makes the transcript parser depend on shell completeness. That means whether a line is a transcript opcode depends on prior shell syntax, error behavior depends on mvdan/sh parser details, and future transcript syntax changes become riskier because raw command bodies can silently absorb lines.

For a snapshot-test format, the explicit continuation opcode in #6 is easier to read and review. It keeps .cmdt visibly line-oriented: command input lines are marked as command input, while assertions stay assertions.

@brandonbloom

Copy link
Copy Markdown
Member Author

Closing in favor of #6, which uses explicit command continuation lines.

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