`/terminal-setup` clobbers iTerm2 keybindings

Status Fixed / completed
Maintainer reply ✓ Yes — ashwin-ant
Activity 9 comments · opened Mar 4, 2025 · closed Mar 21, 2025
💡 Likely answer: A maintainer (ashwin-ant, collaborator) responded on this thread — see the highlighted reply below.

When using /terminal-setup to install the Shift + Enter keybinding for typing newlines, all iTerm2 keybindings are overwritten, including the iTerm2 default keybindings.

For other users affected by this issue, you can at least get back the default keybindings by opening settings (Cmd + ,), navigating to "Keys" and "Key Bindings", clicking on "Presets...", selecting "Factory Defaults" and choosing "Keep" to keep the newline keybinding added by Claude Code.

View original on GitHub ↗

9 Comments

ashwin-ant collaborator · 1 year ago

The current implementation should just be adding to the existing file, not clobbering anything. It's possible there's a bug here where something failed partway through though. Thanks for reporting!

vimota · 1 year ago

/terminal-setup Doesn't show up for me - has that been removed?

ashwin-ant collaborator · 1 year ago

It should be showing up. What version are you running? claude -v

vimota · 1 year ago
planar|vimota-imagedata ⇒ claude -v
0.2.38 (Claude Code)
vimota · 1 year ago
ashwin-ant collaborator · 1 year ago

@vimota what terminal/OS combo are you on? The command only works in iTerm and VSCode.

vimota · 1 year ago

It's iTerm and macOS 15. Is it possible that I've previously run it so it doesn't show? (though I don't recall running it)

ashwin-ant collaborator · 1 year ago

We've put in a fix to make this more robust against clobbering settings. Really sorry this happened to you.

github-actions[bot] · 1 year ago

This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.