Double-press Cmd+L silently destroys entire session with no confirmation
Summary
Pressing Cmd+L (or Ctrl+L) twice within two seconds runs /clear, which irreversibly wipes the entire conversation — including sessions that may represent days of accumulated context and hundreds of thousands of tokens. There is no confirmation prompt, no undo, and no way to recover.
The Problem
The chat:clearInput action has a hidden escalation: a single press redraws the screen, but a double press nukes the session. This is a UX anti-pattern for several reasons:
- The most destructive action in the tool is triggered by a casual double-tap of a common shortcut.
Cmd+Lis muscle memory for "clear screen" in every terminal emulator — users will double-tap it without thinking.
- There is zero confirmation. No "Are you sure?" dialog, no way to undo. The session is simply gone.
- The escalation behavior is not discoverable. Nothing in the UI warns that pressing the same key twice will do something catastrophically different from pressing it once.
- The two behaviors (redraw screen vs. destroy session) are bundled into a single, inseparable action. You cannot keep the useful single-press behavior without accepting the destructive double-press. The keybindings system does not allow separating them.
Impact
For workflows involving long-running sessions (multi-day, 100k+ tokens of accumulated context, ongoing architectural work), an accidental /clear is the single most destructive thing that can happen. It's not recoverable, and rebuilding that context is hours of work — if it's even possible.
Request
- Add a confirmation prompt before
/clear— at minimum for sessions above a certain size or age. This is an irreversible, destructive action and should be treated as one.
- Separate
clearInput(screen redraw) andclearConversationinto independent, separately bindable actions. Users should be able to keep one without the other.
- More broadly: destructive behaviors like this should be opt-in, not mandatory defaults. Adding a hidden session-destroying escalation to a screen-redraw shortcut is not something that should ship as a default that users have to discover the hard way. Features with this level of blast radius should require explicit user opt-in.
Current Workaround
Unbinding Cmd+L, Ctrl+L, Cmd+K, and Meta+K entirely in keybindings.json, which also loses the useful screen redraw functionality.
Thank you for building Claude Code — it's an incredible tool and central to my daily workflow. That's precisely why getting this right matters so much.
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗