[Bug] Bash permission prompt option 2 label truncated with long commands
Bug Description
When the bash permission prompt ("Do you want to proceed?") shows a long command, option 2 ("Yes, and don't ask again") renders incorrectly:
The label is truncated: it displays Yes, and don't ask agai: — the end of "again" is cut off, so the text appears to be clipped mid-word.
The command shown after the label wraps across multiple lines with broken indentation. The word for ends up alone on its own line, and the rest of the command is pushed to a large left margin that doesn't align with anything.
The result is that option 2 is nearly unreadable, while options 1 and 3 render fine.
Steps to reproduce
Run a command long enough to wrap in the terminal (see example below).
When the permission prompt appears, observe option 2.
Example command:
.venv/bin/python -c "import rasterio, numpy, matplotlib, geopandas, shapely, PIL, requests; print('rasterio',rasterio.__version__); print('numpy',numpy.__version__); print('geopandas',geopandas.__version__); print('shapely',shapely.__version__); print('matplotlib',matplotlib.__version__); print('PIL',PIL.__version__); print('ALL OK')"
Expected behavior
Long commands in option 2 should either be truncated cleanly (e.g. with …), wrapped with consistent indentation, or shortened so the label ("Yes, and don't ask again") is always shown in full.
Actual behavior
The label is clipped (agai) and the command text wraps with inconsistent indentation and an orphaned word (for).
Environment
OS: <e.g. macOS 14.5>
Terminal: <e.g. iTerm2 / Terminal.app / Windows Terminal>
Tool version: <fill in>
Terminal width / window size: <columns, if known>
A screenshot is attached.
<img width="1508" height="468" alt="Image" src="https://github.com/user-attachments/assets/09952cb9-2b77-4947-a8c6-cb08251fdfdb" />
Environment Info
- Platform: darwin
- Terminal: ghostty
- Version: 2.1.183
- Feedback ID: 79120412-1ca9-46bc-9a20-022cf75bf6b3
Errors
[]