Skip to content

feat: Add --variant flag to root opencode command - #7358

Closed
ekweible wants to merge 1 commit into
anomalyco:devfrom
ekweible:feat/cli-root-variant-flag
Closed

ekweible wants to merge 1 commit into
anomalyco:devfrom
ekweible:feat/cli-root-variant-flag

Conversation

@ekweible

@ekweible ekweible commented Jan 8, 2026

Copy link
Copy Markdown

Closes #7354

Summary

Adds --variant flag to root opencode command, matching existing support in opencode run.

Changes

  • thread.ts: Add --variant option to yargs builder, pass to tui args
  • args.tsx: Add variant to Args interface
  • local.tsx: Initialize variant from CLI arg using model.variant.set()

This is my first contribution here, so please let me know if I've missed something! I didn't see any existing test coverage for the CLI args or the TUI local context, but I'm happy to add tests if desired.

@github-actions

github-actions Bot commented Jan 8, 2026

Copy link
Copy Markdown
Contributor

The following comment was made by an LLM, it may be inaccurate:

No duplicate PRs found

@gjermundgaraba

Copy link
Copy Markdown

As mentioned in #7354 (comment): my fork's version of this feature. Feel free to use anything there if useful!

4d67c5e

Brings parity with `opencode run` which already supports --variant.
Allows users to specify reasoning effort when launching TUI with --prompt.
@ramarivera

Copy link
Copy Markdown

super interested in this ! LMK if some testing is needed or whatever :)

@zclllyybb

Copy link
Copy Markdown

any progress?

@matleh

matleh commented Sep 18, 2026

Copy link
Copy Markdown

Anything needed to move this forward?
Would be helpful in automation.

@thdxr

thdxr commented Oct 10, 2026

Copy link
Copy Markdown
Member

This branch has been upgraded to V2. We're no longer taking PRs for V1. If you think this is still relevant, please port it over and open it for V2.

— from 𝕺𝖕𝖊𝖓𝕮𝖔𝖉𝖊

@thdxr thdxr closed this Oct 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE]: Add --variant flag to root opencode command

6 participants