Skip to content

fix(tui): preserve multiline shell input#27092

Open
js0ny wants to merge 1 commit into
anomalyco:devfrom
js0ny:fix-shell-multiline
Open

fix(tui): preserve multiline shell input#27092
js0ny wants to merge 1 commit into
anomalyco:devfrom
js0ny:fix-shell-multiline

Conversation

@js0ny
Copy link
Copy Markdown

@js0ny js0ny commented May 12, 2026

Issue for this PR

Closes #27080

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

Fixes pasted multi-line shell commands in bash/zsh shell mode.

The wrapper previously embedded commands via JSON.stringify(command) before eval, which escaped real newlines as \n.

This patch passes the command as an argv entry instead of interpolating it into the wrapper script source.

How did you verify your code works?

  • bun test test/session/prompt.test.ts --test-name-pattern "shell preserves newlines with configured bash"
  • bun typecheck

Screenshots / recordings

Not a UI change

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

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.

[BUG]: Shell mode escapes pasted newlines in multi-line commands

1 participant