diff --git a/scripts/lib/worktree.mjs b/scripts/lib/worktree.mjs index 719e237..4238341 100644 --- a/scripts/lib/worktree.mjs +++ b/scripts/lib/worktree.mjs @@ -17,8 +17,15 @@ export const PLAN_BRANCH_PREFIX = 'plans/plan-issue' /** Env var the interactive-terminal `worktree()` function sets to request the opencode launch. */ export const WORKTREE_TERMINAL_ENV = 'TEQO_WORKTREE_TERMINAL' -/** Preset model for the opencode launch — change the preset by editing this constant. */ -export const OPENCODE_PRESET_MODEL = 'deepseek/deepseek-v4-flash' +/** + * Preset model for the opencode launch — fallback comum aos 3 repos do fluxo + * (infra-solla, teqo, iara-pwa). Override sem editar código: global via + * `export OPENCODE_WORKTREE_MODEL=…` no profile (~/.bashrc), ou por repo na + * chave `OPENCODE_WORKTREE_MODEL` da `.forgejo/worktree.env` (o roteador + * `worktree()` exporta a chave antes de rodar este script). + */ +export const OPENCODE_PRESET_MODEL = + process.env.OPENCODE_WORKTREE_MODEL || 'deepseek/deepseek-v4-flash' /** * Skill command sent as the launch's initial message per purpose. `next`