Exit-screen resume command always says "opencode", even when invoked as opencode2
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 88/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- typescript
- Domain
- cli
Research direction
Start in packages/opencode/src/cli/cmd/run/splash.ts and inspect the build() function's exit branch, along with how the launched command name is available there. Make the resume hint use the invoked binary name instead of hardcoding opencode, then verify the exit screen when launching through opencode2.
Written by the indexing model from the issue text.
Description
Description
The published `@opencode/cli` package registers this binary under two bin names, `opencode` and `opencode2` (so a v2 install doesn't clobber a separately installed v1 `opencode`). When you exit an interactive session, the exit splash prints a resume command to copy-paste, but it always hardcodes the literal string `opencode --mini -s `, regardless of which name you actually launched the binary with.
If `opencode` in your PATH resolves to something else (e.g. a separate v1 install, as in my case), the printed resume command runs the wrong binary and fails to find the session — the hint should say `opencode2 --mini -s ` when that's how it was invoked.
The hardcoded string is in `packages/opencode/src/cli/cmd/run/splash.ts` (the `build()` function's "exit" branch).
Plugins
opencode-pty, oh-my-opencode-slim
OpenCode version
2.0.7 (installed as `opencode2`)
Steps to reproduce
- Install `@opencode/cli` such that it's available as `opencode2` in PATH (e.g. because `opencode` already points at a separate v1 install).
- Run `opencode2` and start an interactive session.
- Exit the session.
- The exit screen prints `Continue opencode --mini -s ses_...` instead of `opencode2 --mini -s ses_...`.
- Running the printed command invokes the wrong binary and can't resume the session.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- Avg merge
- 7h 20m
- Merged PRs (30d)
- 358
Contributor guide
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 anomalyco/opencode
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
[FEATURE]: Bump gitlab-ai-provider to 6.15.1 on v2 (Fable 5.1, GPT-6 Astra, workflow reconnect fix) Open
Difficulty 1/5 Under an hour Newbie friendliness 90/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
All issues in anomalyco/opencode
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Eynzof/Hermes-CN-Desktop#610 ·
-
bug clawsweeper:linked-pr-open clawsweeper:needs-live-repro clawsweeper:no-new-fix-pr impact:message-loss issue-rating: 🐚 platinum hermit P2 regression
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
calcite-components needs triage refactor
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Esri/calcite-design-system#15203 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 78/100
fullcalendar/fullcalendar#8106 ·