Bug Description
Ctrl+M (which should send the same key code as Enter, ASCII 13 / carriage return) does not behave the same as the Enter key when used in interactive TUI applications (specifically Claude Code CLI).
Input submitted via Ctrl+M is sent but the user's input text is not displayed in the application's chat history. The same input submitted via the Enter key displays correctly.
Steps to Reproduce
- Launch Ghostty
- Run an interactive TUI application (e.g., Claude Code:
claude)
- Type any text in the input field
- Press
Ctrl+M to submit
- Observe that the user's input text is not displayed
Expected Behavior
Ctrl+M should behave identically to the Enter key, as both should send carriage return (0x0D).
Actual Behavior
Enter → input text displayed correctly
Ctrl+M → input text sent but not displayed
Comparison with other terminals
- Terminal.app (macOS): Ctrl+M works correctly, same as Enter
- Ghostty (no Zellij): Ctrl+M fails for any length of input
- Ghostty + Zellij: Ctrl+M fails for single character input, works for 2+ characters (Zellij partially compensates)
Environment
- Ghostty version: latest
- OS: macOS 26.3.1 (Apple M2)
- Ghostty config:
macos-option-as-alt = left
- Application tested: Claude Code CLI v2.1.74
Bug Description
Ctrl+M (which should send the same key code as Enter, ASCII 13 / carriage return) does not behave the same as the Enter key when used in interactive TUI applications (specifically Claude Code CLI).
Input submitted via Ctrl+M is sent but the user's input text is not displayed in the application's chat history. The same input submitted via the Enter key displays correctly.
Steps to Reproduce
claude)Ctrl+Mto submitExpected Behavior
Ctrl+M should behave identically to the Enter key, as both should send carriage return (0x0D).
Actual Behavior
Enter→ input text displayed correctlyCtrl+M→ input text sent but not displayedComparison with other terminals
Environment