[Feature Request] Auto-copy resume command to clipboard on Ctrl+C or app close

Resolved 💬 2 comments Opened Apr 14, 2026 by StevanusPangau Closed May 16, 2026

What variant of Codex are you using?

CLI

What feature would you like to see?

I’d like to request a small UX improvement for Codex that would be very helpful in real usage.

Problem
When I stop Codex with Ctrl+C or close the app/session, I often want to continue later using the resume command, for example:

codex resume 019d8b21-218a-7e52-83ab-524ced01f3e0

Right now, I need to manually copy the session ID first. This becomes inconvenient especially when:

  • I hit usage limits
  • I want to switch accounts
  • I need to close Codex quickly and continue later

Requested feature
On Ctrl+C, graceful shutdown, or window/app close, automatically copy the full resume command to the clipboard, for example:

codex resume 019d8b21-218a-7e52-83ab-524ced01f3e0

Why this helps
This is a small change, but it would make session recovery much faster and smoother. The main benefit is reducing friction when users need to:

  • switch accounts
  • recover after limit exhaustion
  • reopen Codex and continue immediately

Suggested behavior
If possible:

  1. On exit, Codex detects that the current session is resumable
  2. It copies codex resume <session_id> to the clipboard automatically
  3. It also prints a message like:

Resume command copied to clipboard: codex resume <session_id>

Optional improvements

  • Add a setting/flag to enable or disable this behavior
  • Fallback to printing the resume command clearly if clipboard access fails
  • Support this on macOS, Linux, and Windows

This is a small update, but it would be very helpful in daily workflows.

Thanks.

Additional information

_No response_

View original on GitHub ↗

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