[FEATURE] opt-in exit confirmation

Resolved 💬 2 comments Opened Mar 5, 2026 by ndyelsey Closed Apr 2, 2026

Preflight Checklist

  • [x] I have searched existing requests and this feature hasn't been requested yet
  • [x] This is a single feature request (not multiple features)

Problem Statement

I have accidentally terminated Claude Code sessions that are in the middle of long runs. The --continue and --resume are poor recovery mechanisms, and this has resulted in lost work. There should be an option to trap exit requests and confirm that it was intentional. This is pretty universal in the applications world, and would really improve Claude Codes usage safety.

Proposed Solution

Really simple -- provide an option (or make it the default) for Claude Code to confirm an exit request before terminating a session.

Alternative Solutions

_No response_

Priority

Critical - Blocking my work

Feature Category

CLI commands and flags

Use Case Example

_No response_

Additional Context

_No response_

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗