mirror of
https://github.com/anomalyco/opencode.git
synced 2026-07-21 18:26:09 +00:00
18 lines
500 B
TypeScript
18 lines
500 B
TypeScript
export * as ConfigReference from "./reference"
|
|
|
|
import { Schema } from "effect"
|
|
|
|
export class Git extends Schema.Class<Git>("ConfigV2.Reference.Git")({
|
|
repository: Schema.String,
|
|
branch: Schema.String.pipe(Schema.optional),
|
|
}) {}
|
|
|
|
export class Local extends Schema.Class<Local>("ConfigV2.Reference.Local")({
|
|
path: Schema.String,
|
|
}) {}
|
|
|
|
export const Entry = Schema.Union([Schema.String, Git, Local])
|
|
export type Entry = typeof Entry.Type
|
|
|
|
export const Info = Schema.Record(Schema.String, Entry)
|