Submit initial OpenCode 2.0.12 prompts through the native startup plugin (#25428)

* fix(opencode): submit initial prompts for reviewed 2.0.12

Route the reported release through the existing native startup intent.
Retain conservative behavior for other unreviewed versions.

* Wait for OpenCode startup fixture file reads in the hydration test

---------

Co-authored-by: nwparker <nwparker@users.noreply.github.com>
This commit is contained in:
Neil
2026-10-05 03:08:22 -07:00
committed by GitHub
co-authored by nwparker
parent 40f9e7a3fc
commit 8b5de39217
5 changed files with 107 additions and 42 deletions
+8 -1
View File
@@ -1,5 +1,7 @@
import { isValidAppVersion } from './app-version'
export const OPENCODE_NATIVE_PROMPT_VERSIONS = ['2.0.12', '2.0.16'] as const
export type OpenCodeCliCapabilities = {
version: string | null
pluginApi: 'v1' | 'v2' | 'unknown'
@@ -21,6 +23,11 @@ export function getOpenCodeCliCapabilities(
return {
version,
pluginApi: major === '1' ? 'v1' : major === '2' ? 'v2' : 'unknown',
promptMode: major === '1' ? 'submit' : version === '2.0.16' ? 'prefill' : 'unknown'
promptMode:
major === '1'
? 'submit'
: OPENCODE_NATIVE_PROMPT_VERSIONS.some((supported) => supported === version)
? 'prefill'
: 'unknown'
}
}