Add CLI commands to list and promote managed Codex accounts
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 54/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Active
- Tech stack
- swift
- Domain
- authentication, cli
Research direction
Start by tracing the existing managed-account promotion path in the app target and how CodexBarCLI depends on CodexBarCore. Move only the reusable operation as needed, then add list/promote handling with temporary account stores and synthetic auth.json fixtures; done means safe, atomic, private switching, locking against concurrent promotions, and no credential output.
Written by the indexing model from the issue text.
Description
CodexBar already supports multiple managed Codex accounts and lets the user promote one of them to the System Account from the app.
I would like to expose the same explicit operation through the bundled CLI. This would make it possible to change the account used by newly started Codex processes from a terminal or an SSH session on the same Mac.
Suggested command shape:
codexbar codex-accounts list
codexbar codex-accounts promote <id-or-email>
promote is intentional here. The command would change the system Codex authentication, not just the account selected for display in CodexBar.
Expected scope:
listshows the managed account label or email, its stable CodexBar ID, and which account currently matches the live system authenticationpromotereuses the existing managed-account promotion behavior- the current, potentially refreshed live credentials are preserved in the matching managed account before switching
- the live
auth.jsonreplacement remains atomic and private - ambiguous, missing, or unreadable account state fails without replacing the live authentication
- app and CLI promotions cannot modify the account store concurrently
The commands must never print access tokens or other credential contents.
Existing Codex processes may retain the identity they started with. The command should not terminate or restart them automatically.
Adding accounts, OAuth login, automatic rotation, quota-based switching, and remote profile synchronization are out of scope. This is a manual operation only. It is related to #2851, but does not implement the automatic depletion policy requested there. It also follows the provider-specific switching direction described in #1843.
The promotion implementation currently lives in the app target, while CodexBarCLI depends on CodexBarCore. If this direction is welcome, the smallest implementation appears to be moving the reusable promotion path into Core, keeping app-specific refresh and UI handling in the app target, and adding a shared process lock around promotion.
Tests can use temporary account stores and synthetic auth.json fixtures only, without reading real credentials or triggering Keychain prompts.
Would this scoped CLI surface be welcome before I prepare a PR?
- Dominant language
- Swift
- Stars
- 21.6k
- Forks
- 2k
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 385
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from steipete/CodexBar
-
clawsweeper:needs-live-repro clawsweeper:needs-maintainer-review clawsweeper:no-new-fix-pr impact:ux-friction issue-rating: 🐚 platinum hermit P2
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
clawsweeper:needs-maintainer-review clawsweeper:needs-product-decision clawsweeper:no-new-fix-pr clawsweeper:source-repro impact:ux-friction issue-rating: 🦞 diamond lobster P2
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
clawsweeper:needs-maintainer-review clawsweeper:needs-product-decision clawsweeper:no-new-fix-pr impact:ux-friction issue-rating: 🌊 off-meta tidepool P3
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
clawsweeper:needs-maintainer-review clawsweeper:needs-product-decision clawsweeper:needs-security-review clawsweeper:no-new-fix-pr impact:auth-provider impact:security issue-rating: 🌊 off-meta tidepool P2
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
-
impact:ux-friction issue-rating: 🦪 silver shellfish P2
Difficulty 3/5 1-2 days Newbie friendliness 65/100
All issues in steipete/CodexBar
Similar issues
-
tvOS
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
skiptools/skip-fuse-ui#147 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
OneBusAway/onebusaway-ios#1438 · 1 reaction ·