Skip to content

fix(tui): show full command in preview instead of truncating - #81

Merged
JoseVelazcoH merged 1 commit into
developfrom
fix/preview-truncated-command
Jul 6, 2026
Merged

JoseVelazcoH merged 1 commit into
developfrom
fix/preview-truncated-command

Conversation

@JoseVelazcoH

Copy link
Copy Markdown
Owner

Summary

The TUI preview pane cut long commands to a single line with an ellipsis. Now the command is shown in full, wrapped across as many lines as needed.

Motivation

A long command (e.g. git fetch ... && git checkout <long-branch>) was truncated in the preview, so you couldn't read what you were about to run or replay.

Changes

  • Stop truncating the command line in render_preview; rely on the paragraph's existing Wrap to lay it out across lines.
  • Add a TestBackend test asserting the tail of a long command is visible in the preview.

Test plan

  • Unit tests added / updated (660 passing)
  • Integration tests added / updated
  • Tested locally with cargo test
  • Manual: rendered preview buffer shows the full wrapped command

Review checklist

  • Follows commit convention
  • No raw SQL without parameterized queries
  • No ORM or migration library introduced
  • cargo fmt and cargo clippy clean (pre-existing search.rs MSRV warning unrelated)
  • Docs updated if public API changed (n/a)

Breaking changes

None.

The preview pane truncated the command to a single line with an ellipsis;
let the existing paragraph wrap render it in full across lines.
@JoseVelazcoH JoseVelazcoH added the type: bug Something isn't working label Jul 6, 2026
@JoseVelazcoH JoseVelazcoH self-assigned this Jul 6, 2026
@JoseVelazcoH JoseVelazcoH added the type: test Testing related label Jul 6, 2026
@JoseVelazcoH
JoseVelazcoH merged commit de92213 into develop Jul 6, 2026
5 checks passed
@JoseVelazcoH
JoseVelazcoH deleted the fix/preview-truncated-command branch July 6, 2026 16:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type: bug Something isn't working type: test Testing related

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant