feat(plugin): add v2 effect host (#33111)

This commit is contained in:
Dax
2026-06-21 14:05:49 +02:00
committed by GitHub
parent 7a9337da8a
commit c780d7cee7
139 changed files with 3749 additions and 1952 deletions
+15
View File
@@ -0,0 +1,15 @@
import type { CommandV2Info } from "@opencode-ai/sdk/v2/types"
import type { Effect } from "effect"
import type { Transformable } from "./registration.js"
export interface CommandDraft {
list(): readonly CommandV2Info[]
get(name: string): CommandV2Info | undefined
update(name: string, update: (command: CommandV2Info) => void): void
remove(name: string): void
}
export interface Command extends Transformable<CommandDraft> {
get(name: string): Effect.Effect<CommandV2Info | undefined>
list(): Effect.Effect<CommandV2Info[]>
}