mirror of
https://github.com/aljazceru/opencode.git
synced 2025-12-21 09:44:21 +01:00
add plugin hook for config
This commit is contained in:
@@ -8,6 +8,7 @@ import type {
|
||||
UserMessage,
|
||||
Part,
|
||||
Auth,
|
||||
Config,
|
||||
} from "@opencode-ai/sdk"
|
||||
import type { BunShell } from "./shell"
|
||||
|
||||
@@ -20,6 +21,7 @@ export type Plugin = (input: PluginInput) => Promise<Hooks>
|
||||
|
||||
export interface Hooks {
|
||||
event?: (input: { event: Event }) => Promise<void>
|
||||
config?: (input: Config) => Promise<void>
|
||||
auth?: {
|
||||
provider: string
|
||||
loader?: (auth: () => Promise<Auth>, provider: Provider) => Promise<Record<string, any>>
|
||||
|
||||
Reference in New Issue
Block a user