SIGN IN SIGN UP
openai / codex UNCLAIMED

Lightweight coding agent that runs in your terminal

0 0 110 Rust

Add thread archive CLI commands (#25021)

## Problem

Saved threads can already be archived through app-server RPCs, but the
command line did not expose direct archive or unarchive commands.

## Solution

Add `codex archive <thread>` and `codex unarchive <thread>`, resolving
UUIDs or exact thread names before calling the existing `thread/archive`
and `thread/unarchive` RPCs. The commands support scoped remote flags so
callers can target remote app-server endpoints when archiving or
unarchiving threads.

This also fixes a long-standing bug in `codex resume <thread id>` and
`codex fork <thread id>` that I found when testing the new commands.
These operations shouldn't be allowed on archived sessions. They now
fail with an error that tells the user to run `codex unarchive <thread
id>` first.

## Verification

Added app-server coverage for rejecting archived thread resume by id and
checking that the error includes the matching `codex unarchive <thread
id>` command.
E
Eric Traut committed
3e7baa00e43419967d90d6ad9cef40f58d5ac89f
Parent: e0435af
Committed by GitHub <noreply@github.com> on 5/30/2026, 6:37:26 AM