feat(schema): publish package

This commit is contained in:
Dax Raad
2026-07-01 13:33:59 -04:00
parent d51ba6ed94
commit 5e47501b8b
77 changed files with 413 additions and 325 deletions
+2
View File
@@ -722,6 +722,7 @@
}, },
"packages/schema": { "packages/schema": {
"name": "@opencode-ai/schema", "name": "@opencode-ai/schema",
"version": "1.17.11",
"dependencies": { "dependencies": {
"effect": "catalog:", "effect": "catalog:",
}, },
@@ -729,6 +730,7 @@
"@tsconfig/bun": "catalog:", "@tsconfig/bun": "catalog:",
"@types/bun": "catalog:", "@types/bun": "catalog:",
"@typescript/native-preview": "catalog:", "@typescript/native-preview": "catalog:",
"typescript": "catalog:",
}, },
}, },
"packages/script": { "packages/script": {
+15 -2
View File
@@ -1,14 +1,26 @@
{ {
"$schema": "https://json.schemastore.org/package.json", "$schema": "https://json.schemastore.org/package.json",
"name": "@opencode-ai/schema", "name": "@opencode-ai/schema",
"private": true, "version": "1.17.11",
"type": "module", "type": "module",
"license": "MIT", "license": "MIT",
"repository": {
"type": "git",
"url": "git+https://github.com/anomalyco/opencode.git",
"directory": "packages/schema"
},
"publishConfig": {
"access": "public"
},
"files": [
"dist"
],
"exports": { "exports": {
".": "./src/index.ts", ".": "./src/index.ts",
"./*": "./src/*.ts" "./*": "./src/*.ts"
}, },
"scripts": { "scripts": {
"build": "bun run script/build.ts",
"typecheck": "tsgo --noEmit" "typecheck": "tsgo --noEmit"
}, },
"dependencies": { "dependencies": {
@@ -17,6 +29,7 @@
"devDependencies": { "devDependencies": {
"@tsconfig/bun": "catalog:", "@tsconfig/bun": "catalog:",
"@types/bun": "catalog:", "@types/bun": "catalog:",
"@typescript/native-preview": "catalog:" "@typescript/native-preview": "catalog:",
"typescript": "catalog:"
} }
} }
+9
View File
@@ -0,0 +1,9 @@
#!/usr/bin/env bun
import { $ } from "bun"
import { fileURLToPath } from "node:url"
process.chdir(fileURLToPath(new URL("..", import.meta.url)))
await $`rm -rf dist`
await $`bun tsc -p tsconfig.build.json`
+45
View File
@@ -0,0 +1,45 @@
#!/usr/bin/env bun
import { Script } from "@opencode-ai/script"
import { $ } from "bun"
import { rm } from "node:fs/promises"
import { fileURLToPath } from "node:url"
process.chdir(fileURLToPath(new URL("..", import.meta.url)))
const originalText = await Bun.file("package.json").text()
const pkg = JSON.parse(originalText) as {
name: string
version: string
exports: Record<string, string | { import: string; types: string }>
}
const tarball = `${pkg.name.replace("@", "").replace("/", "-")}-${pkg.version}.tgz`
if ((await $`npm view ${pkg.name}@${pkg.version} version`.nothrow()).exitCode === 0) {
console.log(`already published ${pkg.name}@${pkg.version}`)
process.exit(0)
}
try {
await $`bun run typecheck`
await $`bun run build`
pkg.exports = Object.fromEntries(
Object.entries(pkg.exports).map(([key, value]) => {
if (typeof value !== "string") return [key, value]
return [
key,
{
import: value.replace("./src/", "./dist/").replace(/\.ts$/, ".js"),
types: value.replace("./src/", "./dist/").replace(/\.ts$/, ".d.ts"),
},
]
}),
)
await Bun.write("package.json", JSON.stringify(pkg, null, 2) + "\n")
await rm(tarball, { force: true })
await $`bun pm pack`
await $`npm publish ${tarball} --tag ${Script.channel} --access public`
} finally {
await Bun.write("package.json", originalText)
await rm(tarball, { force: true })
}
+7 -7
View File
@@ -1,12 +1,12 @@
export * as Agent from "./agent" export * as Agent from "./agent.js"
import { Schema } from "effect" import { Schema } from "effect"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
import { optional } from "./schema" import { optional } from "./schema.js"
import { Model } from "./model" import { Model } from "./model.js"
import { Permission } from "./permission" import { Permission } from "./permission.js"
import { Provider } from "./provider" import { Provider } from "./provider.js"
import { PositiveInt, statics } from "./schema" import { PositiveInt, statics } from "./schema.js"
const Updated = define({ type: "agent.updated", schema: {} }) const Updated = define({ type: "agent.updated", schema: {} })
+2 -2
View File
@@ -1,6 +1,6 @@
export * as Catalog from "./catalog" export * as Catalog from "./catalog.js"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
const Updated = define({ type: "catalog.updated", schema: {} }) const Updated = define({ type: "catalog.updated", schema: {} })
export const Event = { Updated, Definitions: inventory(Updated) } export const Event = { Updated, Definitions: inventory(Updated) }
+3 -3
View File
@@ -1,8 +1,8 @@
export * as Command from "./command" export * as Command from "./command.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { Model } from "./model" import { Model } from "./model.js"
export interface Info extends Schema.Schema.Type<typeof Info> {} export interface Info extends Schema.Schema.Type<typeof Info> {}
export const Info = Schema.Struct({ export const Info = Schema.Struct({
+2 -2
View File
@@ -1,7 +1,7 @@
export * as Connection from "./connection" export * as Connection from "./connection.js"
import { Schema } from "effect" import { Schema } from "effect"
import { Credential } from "./credential" import { Credential } from "./credential.js"
export interface CredentialInfo extends Schema.Schema.Type<typeof CredentialInfo> {} export interface CredentialInfo extends Schema.Schema.Type<typeof CredentialInfo> {}
export const CredentialInfo = Schema.Struct({ export const CredentialInfo = Schema.Struct({
+5 -5
View File
@@ -1,10 +1,10 @@
export * as Credential from "./credential" export * as Credential from "./credential.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { IntegrationMethodID } from "./integration-id" import { IntegrationMethodID } from "./integration-id.js"
import { ascending } from "./identifier" import { ascending } from "./identifier.js"
import { NonNegativeInt, statics } from "./schema" import { NonNegativeInt, statics } from "./schema.js"
export const ID = Schema.String.pipe( export const ID = Schema.String.pipe(
Schema.brand("Credential.ID"), Schema.brand("Credential.ID"),
@@ -1,8 +1,8 @@
export * as DurableEventManifest from "./durable-event-manifest" export * as DurableEventManifest from "./durable-event-manifest.js"
import { Event } from "./event" import { Event } from "./event.js"
import { SessionEvent } from "./session-event" import { SessionEvent } from "./session-event.js"
import { SessionV1 } from "./session-v1" import { SessionV1 } from "./session-v1.js"
export const SessionDurable = { export const SessionDurable = {
definitions: Event.durable(SessionEvent.DurableDefinitions), definitions: Event.durable(SessionEvent.DurableDefinitions),
+33 -33
View File
@@ -1,37 +1,37 @@
export * as EventManifest from "./event-manifest" export * as EventManifest from "./event-manifest.js"
import { Agent } from "./agent" import { Agent } from "./agent.js"
import { Catalog } from "./catalog" import { Catalog } from "./catalog.js"
import { Durable } from "./durable-event-manifest" import { Durable } from "./durable-event-manifest.js"
import { Event } from "./event" import { Event } from "./event.js"
import { FileSystem } from "./filesystem" import { FileSystem } from "./filesystem.js"
import { FileSystemWatcher } from "./filesystem-watcher" import { FileSystemWatcher } from "./filesystem-watcher.js"
import { InstallationEvent } from "./installation-event" import { InstallationEvent } from "./installation-event.js"
import { Integration } from "./integration" import { Integration } from "./integration.js"
import { LegacyEvent } from "./legacy-event" import { LegacyEvent } from "./legacy-event.js"
import { LspEvent } from "./lsp-event" import { LspEvent } from "./lsp-event.js"
import { McpEvent } from "./mcp-event" import { McpEvent } from "./mcp-event.js"
import { ModelsDev } from "./models-dev" import { ModelsDev } from "./models-dev.js"
import { Permission } from "./permission" import { Permission } from "./permission.js"
import { PermissionV1 } from "./permission-v1" import { PermissionV1 } from "./permission-v1.js"
import { Plugin } from "./plugin" import { Plugin } from "./plugin.js"
import { Project } from "./project" import { Project } from "./project.js"
import { ProjectDirectories } from "./project-directories" import { ProjectDirectories } from "./project-directories.js"
import { Pty } from "./pty" import { Pty } from "./pty.js"
import { Question } from "./question" import { Question } from "./question.js"
import { QuestionV1 } from "./question-v1" import { QuestionV1 } from "./question-v1.js"
import { Reference } from "./reference" import { Reference } from "./reference.js"
import { ServerEvent } from "./server-event" import { ServerEvent } from "./server-event.js"
import { Shell } from "./shell" import { Shell } from "./shell.js"
import { SessionCompactionEvent } from "./session-compaction-event" import { SessionCompactionEvent } from "./session-compaction-event.js"
import { SessionEvent } from "./session-event" import { SessionEvent } from "./session-event.js"
import { SessionStatusEvent } from "./session-status-event" import { SessionStatusEvent } from "./session-status-event.js"
import { SessionTodo } from "./session-todo" import { SessionTodo } from "./session-todo.js"
import { SessionV1 } from "./session-v1" import { SessionV1 } from "./session-v1.js"
import { TuiEvent } from "./tui-event" import { TuiEvent } from "./tui-event.js"
import { VcsEvent } from "./vcs-event" import { VcsEvent } from "./vcs-event.js"
import { WorkspaceEvent } from "./workspace-event" import { WorkspaceEvent } from "./workspace-event.js"
import { WorktreeEvent } from "./worktree-event" import { WorktreeEvent } from "./worktree-event.js"
const sessionV1DurableDefinitions = SessionV1.Event.Definitions.filter((definition) => definition.durable !== undefined) const sessionV1DurableDefinitions = SessionV1.Event.Definitions.filter((definition) => definition.durable !== undefined)
const sessionV1LiveDefinitions = SessionV1.Event.Definitions.filter((definition) => definition.durable === undefined) const sessionV1LiveDefinitions = SessionV1.Event.Definitions.filter((definition) => definition.durable === undefined)
+5 -5
View File
@@ -1,10 +1,10 @@
export * as Event from "./event" export * as Event from "./event.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { ascending } from "./identifier" import { ascending } from "./identifier.js"
import { Location } from "./location" import { Location } from "./location.js"
import { statics } from "./schema" import { statics } from "./schema.js"
export const ID = Schema.String.check(Schema.isStartsWith("evt_")).pipe( export const ID = Schema.String.check(Schema.isStartsWith("evt_")).pipe(
Schema.brand("Event.ID"), Schema.brand("Event.ID"),
+2 -2
View File
@@ -1,7 +1,7 @@
export * as FileDiff from "./file-diff" export * as FileDiff from "./file-diff.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
export const Info = Schema.Struct({ export const Info = Schema.Struct({
file: optional(Schema.String), file: optional(Schema.String),
+2 -2
View File
@@ -1,7 +1,7 @@
export * as FileSystemWatcher from "./filesystem-watcher" export * as FileSystemWatcher from "./filesystem-watcher.js"
import { Schema } from "effect" import { Schema } from "effect"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
const Updated = define({ const Updated = define({
type: "file.watcher.updated", type: "file.watcher.updated",
+4 -4
View File
@@ -1,9 +1,9 @@
export * as FileSystem from "./filesystem" export * as FileSystem from "./filesystem.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
import { NonNegativeInt, PositiveInt, RelativePath } from "./schema" import { NonNegativeInt, PositiveInt, RelativePath } from "./schema.js"
const Edited = define({ const Edited = define({
type: "file.edited", type: "file.edited",
+2 -2
View File
@@ -1,7 +1,7 @@
export * as IdeEvent from "./ide-event" export * as IdeEvent from "./ide-event.js"
import { Schema } from "effect" import { Schema } from "effect"
import { Event } from "./event" import { Event } from "./event.js"
export const Installed = Event.define({ export const Installed = Event.define({
type: "ide.installed", type: "ide.installed",
+29 -29
View File
@@ -1,29 +1,29 @@
export { Agent } from "./agent" export { Agent } from "./agent.js"
export { Command } from "./command" export { Command } from "./command.js"
export { Connection } from "./connection" export { Connection } from "./connection.js"
export { Credential } from "./credential" export { Credential } from "./credential.js"
export { Event } from "./event" export { Event } from "./event.js"
export { FileSystem } from "./filesystem" export { FileSystem } from "./filesystem.js"
export { Integration } from "./integration" export { Integration } from "./integration.js"
export { LLM } from "./llm" export { LLM } from "./llm.js"
export { Location } from "./location" export { Location } from "./location.js"
export { Model } from "./model" export { Model } from "./model.js"
export { Permission } from "./permission" export { Permission } from "./permission.js"
export { PermissionSaved } from "./permission-saved" export { PermissionSaved } from "./permission-saved.js"
export { Project } from "./project" export { Project } from "./project.js"
export { ProjectCopy } from "./project-copy" export { ProjectCopy } from "./project-copy.js"
export { Provider } from "./provider" export { Provider } from "./provider.js"
export { Reference } from "./reference" export { Reference } from "./reference.js"
export { Revert } from "./revert" export { Revert } from "./revert.js"
export { Session } from "./session" export { Session } from "./session.js"
export { SessionInput } from "./session-input" export { SessionInput } from "./session-input.js"
export { SessionMessage } from "./session-message" export { SessionMessage } from "./session-message.js"
export { Shell } from "./shell" export { Shell } from "./shell.js"
export { Skill } from "./skill" export { Skill } from "./skill.js"
export { Pty } from "./pty" export { Pty } from "./pty.js"
export { PtyTicket } from "./pty-ticket" export { PtyTicket } from "./pty-ticket.js"
export { Question } from "./question" export { Question } from "./question.js"
export { Workspace } from "./workspace" export { Workspace } from "./workspace.js"
export { Prompt, Source, FileAttachment, AgentAttachment } from "./prompt" export { Prompt, Source, FileAttachment, AgentAttachment } from "./prompt.js"
export { PromptInput } from "./prompt-input" export { PromptInput } from "./prompt-input.js"
export * from "./schema" export * from "./schema.js"
+2 -2
View File
@@ -1,7 +1,7 @@
export * as InstallationEvent from "./installation-event" export * as InstallationEvent from "./installation-event.js"
import { Schema } from "effect" import { Schema } from "effect"
import { Event } from "./event" import { Event } from "./event.js"
export const Updated = Event.define({ export const Updated = Event.define({
type: "installation.updated", type: "installation.updated",
+7 -7
View File
@@ -1,12 +1,12 @@
export * as Integration from "./integration" export * as Integration from "./integration.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
import { Connection } from "./connection" import { Connection } from "./connection.js"
import { ascending } from "./identifier" import { ascending } from "./identifier.js"
import { statics } from "./schema" import { statics } from "./schema.js"
import { IntegrationID, IntegrationMethodID } from "./integration-id" import { IntegrationID, IntegrationMethodID } from "./integration-id.js"
export const ID = IntegrationID export const ID = IntegrationID
export type ID = typeof ID.Type export type ID = typeof ID.Type
+1 -1
View File
@@ -1 +1 @@
export * from "./v1/legacy-event" export * from "./v1/legacy-event.js"
+2 -2
View File
@@ -1,7 +1,7 @@
export * as LLM from "./llm" export * as LLM from "./llm.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
export const ProviderMetadata = Schema.Record(Schema.String, Schema.Record(Schema.String, Schema.Unknown)).annotate({ export const ProviderMetadata = Schema.Record(Schema.String, Schema.Record(Schema.String, Schema.Unknown)).annotate({
identifier: "LLM.ProviderMetadata", identifier: "LLM.ProviderMetadata",
+4 -4
View File
@@ -1,9 +1,9 @@
export * as Location from "./location" export * as Location from "./location.js"
import { Schema } from "effect" import { Schema } from "effect"
import { AbsolutePath, optional } from "./schema" import { AbsolutePath, optional } from "./schema.js"
import { ProjectID } from "./project-id" import { ProjectID } from "./project-id.js"
import { WorkspaceID } from "./workspace-id" import { WorkspaceID } from "./workspace-id.js"
export interface Ref extends Schema.Schema.Type<typeof Ref> {} export interface Ref extends Schema.Schema.Type<typeof Ref> {}
export const Ref = Schema.Struct({ export const Ref = Schema.Struct({
+2 -2
View File
@@ -1,6 +1,6 @@
export * as LspEvent from "./lsp-event" export * as LspEvent from "./lsp-event.js"
import { Event } from "./event" import { Event } from "./event.js"
export const Updated = Event.define({ type: "lsp.updated", schema: {} }) export const Updated = Event.define({ type: "lsp.updated", schema: {} })
+2 -2
View File
@@ -1,7 +1,7 @@
export * as McpEvent from "./mcp-event" export * as McpEvent from "./mcp-event.js"
import { Schema } from "effect" import { Schema } from "effect"
import { Event } from "./event" import { Event } from "./event.js"
export const ToolsChanged = Event.define({ export const ToolsChanged = Event.define({
type: "mcp.tools.changed", type: "mcp.tools.changed",
+3 -3
View File
@@ -1,8 +1,8 @@
export * as Mcp from "./mcp" export * as Mcp from "./mcp.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { IntegrationID } from "./integration-id" import { IntegrationID } from "./integration-id.js"
const Connected = Schema.Struct({ status: Schema.Literal("connected") }).annotate({ const Connected = Schema.Struct({ status: Schema.Literal("connected") }).annotate({
identifier: "Mcp.Status.Connected", identifier: "Mcp.Status.Connected",
+4 -4
View File
@@ -1,9 +1,9 @@
export * as Model from "./model" export * as Model from "./model.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { Provider } from "./provider" import { Provider } from "./provider.js"
import { statics } from "./schema" import { statics } from "./schema.js"
export const ID = Schema.String.pipe(Schema.brand("ModelV2.ID")) export const ID = Schema.String.pipe(Schema.brand("ModelV2.ID"))
export type ID = typeof ID.Type export type ID = typeof ID.Type
+2 -2
View File
@@ -1,6 +1,6 @@
export * as ModelsDev from "./models-dev" export * as ModelsDev from "./models-dev.js"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
const Refreshed = define({ const Refreshed = define({
type: "models-dev.refreshed", type: "models-dev.refreshed",
+4 -4
View File
@@ -1,9 +1,9 @@
export * as PermissionSaved from "./permission-saved" export * as PermissionSaved from "./permission-saved.js"
import { Schema } from "effect" import { Schema } from "effect"
import { ascending } from "./identifier" import { ascending } from "./identifier.js"
import { ProjectID } from "./project-id" import { ProjectID } from "./project-id.js"
import { statics } from "./schema" import { statics } from "./schema.js"
export const ID = Schema.String.pipe( export const ID = Schema.String.pipe(
Schema.brand("PermissionSaved.ID"), Schema.brand("PermissionSaved.ID"),
+1 -1
View File
@@ -1 +1 @@
export * from "./v1/permission" export * from "./v1/permission.js"
+6 -6
View File
@@ -1,11 +1,11 @@
export * as Permission from "./permission" export * as Permission from "./permission.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
import { ascending } from "./identifier" import { ascending } from "./identifier.js"
import { SessionID } from "./session-id" import { SessionID } from "./session-id.js"
import { statics } from "./schema" import { statics } from "./schema.js"
export const ID = Schema.String.check(Schema.isStartsWith("per")).pipe( export const ID = Schema.String.check(Schema.isStartsWith("per")).pipe(
Schema.brand("PermissionV2.ID"), Schema.brand("PermissionV2.ID"),
+2 -2
View File
@@ -1,7 +1,7 @@
export * as Plugin from "./plugin" export * as Plugin from "./plugin.js"
import { Schema } from "effect" import { Schema } from "effect"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
export const ID = Schema.String.pipe(Schema.brand("Plugin.ID")) export const ID = Schema.String.pipe(Schema.brand("Plugin.ID"))
export type ID = typeof ID.Type export type ID = typeof ID.Type
+4 -4
View File
@@ -1,9 +1,9 @@
export * as ProjectCopy from "./project-copy" export * as ProjectCopy from "./project-copy.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { ProjectID } from "./project-id" import { ProjectID } from "./project-id.js"
import { AbsolutePath } from "./schema" import { AbsolutePath } from "./schema.js"
export const StrategyID = Schema.Trim.pipe(Schema.check(Schema.isNonEmpty()), Schema.brand("ProjectCopy.StrategyID")) export const StrategyID = Schema.Trim.pipe(Schema.check(Schema.isNonEmpty()), Schema.brand("ProjectCopy.StrategyID"))
export type StrategyID = typeof StrategyID.Type export type StrategyID = typeof StrategyID.Type
+3 -3
View File
@@ -1,7 +1,7 @@
export * as ProjectDirectories from "./project-directories" export * as ProjectDirectories from "./project-directories.js"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
import { Project } from "./project" import { Project } from "./project.js"
const Updated = define({ const Updated = define({
type: "project.directories.updated", type: "project.directories.updated",
+1 -1
View File
@@ -1,5 +1,5 @@
import { Schema } from "effect" import { Schema } from "effect"
import { statics } from "./schema" import { statics } from "./schema.js"
export const ProjectID = Schema.String.pipe( export const ProjectID = Schema.String.pipe(
Schema.brand("Project.ID"), Schema.brand("Project.ID"),
+4 -4
View File
@@ -1,9 +1,9 @@
export * as Project from "./project" export * as Project from "./project.js"
import { Schema } from "effect" import { Schema } from "effect"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
import { AbsolutePath, NonNegativeInt, optional } from "./schema" import { AbsolutePath, NonNegativeInt, optional } from "./schema.js"
import { ProjectID } from "./project-id" import { ProjectID } from "./project-id.js"
export const ID = ProjectID export const ID = ProjectID
export type ID = typeof ID.Type export type ID = typeof ID.Type
+3 -3
View File
@@ -1,8 +1,8 @@
export * as PromptInput from "./prompt-input" export * as PromptInput from "./prompt-input.js"
import { Schema } from "effect" import { Schema } from "effect"
import { AgentAttachment, Source } from "./prompt" import { AgentAttachment, Source } from "./prompt.js"
import { optional, statics } from "./schema" import { optional, statics } from "./schema.js"
export interface FileAttachment extends Schema.Schema.Type<typeof FileAttachment> {} export interface FileAttachment extends Schema.Schema.Type<typeof FileAttachment> {}
export const FileAttachment = Schema.Struct({ export const FileAttachment = Schema.Struct({
+2 -2
View File
@@ -1,6 +1,6 @@
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { statics } from "./schema" import { statics } from "./schema.js"
export interface Source extends Schema.Schema.Type<typeof Source> {} export interface Source extends Schema.Schema.Type<typeof Source> {}
export const Source = Schema.Struct({ export const Source = Schema.Struct({
+4 -4
View File
@@ -1,9 +1,9 @@
export * as Provider from "./provider" export * as Provider from "./provider.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { Integration } from "./integration" import { Integration } from "./integration.js"
import { statics } from "./schema" import { statics } from "./schema.js"
export const ID = Schema.String.pipe( export const ID = Schema.String.pipe(
Schema.brand("ProviderV2.ID"), Schema.brand("ProviderV2.ID"),
+2 -2
View File
@@ -1,7 +1,7 @@
export * as PtyTicket from "./pty-ticket" export * as PtyTicket from "./pty-ticket.js"
import { Schema } from "effect" import { Schema } from "effect"
import { PositiveInt } from "./schema" import { PositiveInt } from "./schema.js"
export const ConnectToken = Schema.Struct({ export const ConnectToken = Schema.Struct({
ticket: Schema.String, ticket: Schema.String,
+5 -5
View File
@@ -1,10 +1,10 @@
export * as Pty from "./pty" export * as Pty from "./pty.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
import { ascending } from "./identifier" import { ascending } from "./identifier.js"
import { NonNegativeInt, PositiveInt, statics } from "./schema" import { NonNegativeInt, PositiveInt, statics } from "./schema.js"
const IDSchema = Schema.String.check(Schema.isStartsWith("pty")).pipe(Schema.brand("PtyID")) const IDSchema = Schema.String.check(Schema.isStartsWith("pty")).pipe(Schema.brand("PtyID"))
+1 -1
View File
@@ -1 +1 @@
export * from "./v1/question" export * from "./v1/question.js"
+6 -6
View File
@@ -1,11 +1,11 @@
export * as Question from "./question" export * as Question from "./question.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
import { ascending } from "./identifier" import { ascending } from "./identifier.js"
import { SessionID } from "./session-id" import { SessionID } from "./session-id.js"
import { statics } from "./schema" import { statics } from "./schema.js"
export const ID = Schema.String.check(Schema.isStartsWith("que")).pipe( export const ID = Schema.String.check(Schema.isStartsWith("que")).pipe(
Schema.brand("QuestionV2.ID"), Schema.brand("QuestionV2.ID"),
+4 -4
View File
@@ -1,9 +1,9 @@
export * as Reference from "./reference" export * as Reference from "./reference.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
import { AbsolutePath } from "./schema" import { AbsolutePath } from "./schema.js"
const Updated = define({ type: "reference.updated", schema: {} }) const Updated = define({ type: "reference.updated", schema: {} })
export const Event = { Updated, Definitions: inventory(Updated) } export const Event = { Updated, Definitions: inventory(Updated) }
+4 -4
View File
@@ -1,9 +1,9 @@
export * as Revert from "./revert" export * as Revert from "./revert.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { NonNegativeInt, RelativePath } from "./schema" import { NonNegativeInt, RelativePath } from "./schema.js"
import { SessionMessage } from "./session-message" import { SessionMessage } from "./session-message.js"
export const FileDiff = Schema.Struct({ export const FileDiff = Schema.Struct({
path: RelativePath, path: RelativePath,
+2 -2
View File
@@ -1,6 +1,6 @@
export * as ServerEvent from "./server-event" export * as ServerEvent from "./server-event.js"
import { Event } from "./event" import { Event } from "./event.js"
export const Connected = Event.define({ type: "server.connected", schema: {} }) export const Connected = Event.define({ type: "server.connected", schema: {} })
export const Disposed = Event.define({ type: "global.disposed", schema: {} }) export const Disposed = Event.define({ type: "global.disposed", schema: {} })
@@ -1,7 +1,7 @@
export * as SessionCompactionEvent from "./session-compaction-event" export * as SessionCompactionEvent from "./session-compaction-event.js"
import { Event } from "./event" import { Event } from "./event.js"
import { SessionID } from "./session-id" import { SessionID } from "./session-id.js"
export const Compacted = Event.define({ export const Compacted = Event.define({
type: "session.compacted", type: "session.compacted",
+1 -1
View File
@@ -1,4 +1,4 @@
export * as SessionDelivery from "./session-delivery" export * as SessionDelivery from "./session-delivery.js"
import { Schema } from "effect" import { Schema } from "effect"
+12 -12
View File
@@ -1,17 +1,17 @@
export * as SessionEvent from "./session-event" export * as SessionEvent from "./session-event.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { Event } from "./event" import { Event } from "./event.js"
import { ProviderMetadata, ToolContent } from "./llm" import { ProviderMetadata, ToolContent } from "./llm.js"
import { Delivery } from "./session-delivery" import { Delivery } from "./session-delivery.js"
import { Model } from "./model" import { Model } from "./model.js"
import { DateTimeUtcFromMillis, NonNegativeInt, RelativePath } from "./schema" import { DateTimeUtcFromMillis, NonNegativeInt, RelativePath } from "./schema.js"
import { FileAttachment, Prompt } from "./prompt" import { FileAttachment, Prompt } from "./prompt.js"
import { SessionID } from "./session-id" import { SessionID } from "./session-id.js"
import { Location } from "./location" import { Location } from "./location.js"
import { SessionMessage } from "./session-message" import { SessionMessage } from "./session-message.js"
import { Revert } from "./revert" import { Revert } from "./revert.js"
export { FileAttachment } export { FileAttachment }
+2 -2
View File
@@ -1,6 +1,6 @@
import { Schema } from "effect" import { Schema } from "effect"
import { descending } from "./identifier" import { descending } from "./identifier.js"
import { statics } from "./schema" import { statics } from "./schema.js"
export const SessionID = Schema.String.check(Schema.isStartsWith("ses")).pipe( export const SessionID = Schema.String.check(Schema.isStartsWith("ses")).pipe(
Schema.brand("SessionID"), Schema.brand("SessionID"),
+7 -7
View File
@@ -1,12 +1,12 @@
export * as SessionInput from "./session-input" export * as SessionInput from "./session-input.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { Prompt } from "./prompt" import { Prompt } from "./prompt.js"
import { DateTimeUtcFromMillis, NonNegativeInt } from "./schema" import { DateTimeUtcFromMillis, NonNegativeInt } from "./schema.js"
import { SessionDelivery } from "./session-delivery" import { SessionDelivery } from "./session-delivery.js"
import { SessionID } from "./session-id" import { SessionID } from "./session-id.js"
import { SessionMessage } from "./session-message" import { SessionMessage } from "./session-message.js"
export const Delivery = SessionDelivery.Delivery export const Delivery = SessionDelivery.Delivery
export type Delivery = SessionDelivery.Delivery export type Delivery = SessionDelivery.Delivery
+8 -8
View File
@@ -1,13 +1,13 @@
export * as SessionMessage from "./session-message" export * as SessionMessage from "./session-message.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { ProviderMetadata, ToolContent } from "./llm" import { ProviderMetadata, ToolContent } from "./llm.js"
import { Model } from "./model" import { Model } from "./model.js"
import { FileAttachment, Prompt } from "./prompt" import { FileAttachment, Prompt } from "./prompt.js"
import { DateTimeUtcFromMillis, RelativePath, statics } from "./schema" import { DateTimeUtcFromMillis, RelativePath, statics } from "./schema.js"
import { SessionID } from "./session-id" import { SessionID } from "./session-id.js"
import { ascending } from "./identifier" import { ascending } from "./identifier.js"
export const ID = Schema.String.check(Schema.isStartsWith("msg_")).pipe( export const ID = Schema.String.check(Schema.isStartsWith("msg_")).pipe(
Schema.brand("Session.Message.ID"), Schema.brand("Session.Message.ID"),
+5 -5
View File
@@ -1,10 +1,10 @@
export * as SessionStatusEvent from "./session-status-event" export * as SessionStatusEvent from "./session-status-event.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { Event } from "./event" import { Event } from "./event.js"
import { NonNegativeInt } from "./schema" import { NonNegativeInt } from "./schema.js"
import { SessionID } from "./session-id" import { SessionID } from "./session-id.js"
export const Info = Schema.Union([ export const Info = Schema.Union([
Schema.Struct({ Schema.Struct({
+3 -3
View File
@@ -1,8 +1,8 @@
export * as SessionTodo from "./session-todo" export * as SessionTodo from "./session-todo.js"
import { Schema } from "effect" import { Schema } from "effect"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
import { SessionID } from "./session-id" import { SessionID } from "./session-id.js"
export const Info = Schema.Struct({ export const Info = Schema.Struct({
content: Schema.String.annotate({ description: "Brief description of the task" }), content: Schema.String.annotate({ description: "Brief description of the task" }),
+1 -1
View File
@@ -1 +1 @@
export * from "./v1/session" export * from "./v1/session.js"
+9 -9
View File
@@ -1,14 +1,14 @@
export * as Session from "./session" export * as Session from "./session.js"
import { Schema } from "effect" import { Schema } from "effect"
import { Agent } from "./agent" import { Agent } from "./agent.js"
import { Location } from "./location" import { Location } from "./location.js"
import { Model } from "./model" import { Model } from "./model.js"
import { Project } from "./project" import { Project } from "./project.js"
import { DateTimeUtcFromMillis, optional, RelativePath } from "./schema" import { DateTimeUtcFromMillis, optional, RelativePath } from "./schema.js"
import { SessionEvent } from "./session-event" import { SessionEvent } from "./session-event.js"
import { SessionID } from "./session-id" import { SessionID } from "./session-id.js"
import { Revert } from "./revert" import { Revert } from "./revert.js"
export const ID = SessionID export const ID = SessionID
export type ID = SessionID export type ID = SessionID
+5 -5
View File
@@ -1,10 +1,10 @@
export * as Shell from "./shell" export * as Shell from "./shell.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { define, inventory } from "./event" import { define, inventory } from "./event.js"
import { ascending } from "./identifier" import { ascending } from "./identifier.js"
import { NonNegativeInt, statics } from "./schema" import { NonNegativeInt, statics } from "./schema.js"
const IDSchema = Schema.String.check(Schema.isStartsWith("sh_")).pipe(Schema.brand("ShellID")) const IDSchema = Schema.String.check(Schema.isStartsWith("sh_")).pipe(Schema.brand("ShellID"))
+3 -3
View File
@@ -1,8 +1,8 @@
export * as Skill from "./skill" export * as Skill from "./skill.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { AbsolutePath } from "./schema" import { AbsolutePath } from "./schema.js"
export interface DirectorySource extends Schema.Schema.Type<typeof DirectorySource> {} export interface DirectorySource extends Schema.Schema.Type<typeof DirectorySource> {}
export const DirectorySource = Schema.Struct({ export const DirectorySource = Schema.Struct({
+5 -5
View File
@@ -1,10 +1,10 @@
export * as TuiEvent from "./tui-event" export * as TuiEvent from "./tui-event.js"
import { Effect, Schema } from "effect" import { Effect, Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { Event } from "./event" import { Event } from "./event.js"
import { PositiveInt } from "./schema" import { PositiveInt } from "./schema.js"
import { SessionID } from "./session-id" import { SessionID } from "./session-id.js"
const DEFAULT_TOAST_DURATION = 5000 const DEFAULT_TOAST_DURATION = 5000
+4 -4
View File
@@ -1,9 +1,9 @@
export * as LegacyEvent from "./legacy-event" export * as LegacyEvent from "./legacy-event.js"
import { Schema } from "effect" import { Schema } from "effect"
import { define, inventory } from "../event" import { define, inventory } from "../event.js"
import { SessionID } from "../session-id" import { SessionID } from "../session-id.js"
import { SessionV1 } from "./session" import { SessionV1 } from "./session.js"
export const CommandExecuted = define({ export const CommandExecuted = define({
type: "command.executed", type: "command.executed",
+6 -6
View File
@@ -1,11 +1,11 @@
export * as PermissionV1 from "./permission" export * as PermissionV1 from "./permission.js"
import { Schema } from "effect" import { Schema } from "effect"
import { define, inventory } from "../event" import { define, inventory } from "../event.js"
import { ascending } from "../identifier" import { ascending } from "../identifier.js"
import { Project } from "../project" import { Project } from "../project.js"
import { statics } from "../schema" import { statics } from "../schema.js"
import { SessionID } from "../session-id" import { SessionID } from "../session-id.js"
export const ID = Schema.String.check(Schema.isStartsWith("per")).pipe( export const ID = Schema.String.check(Schema.isStartsWith("per")).pipe(
Schema.brand("PermissionID"), Schema.brand("PermissionID"),
+6 -6
View File
@@ -1,11 +1,11 @@
export * as QuestionV1 from "./question" export * as QuestionV1 from "./question.js"
import { Schema } from "effect" import { Schema } from "effect"
import { define, inventory } from "../event" import { define, inventory } from "../event.js"
import { ascending } from "../identifier" import { ascending } from "../identifier.js"
import { statics } from "../schema" import { statics } from "../schema.js"
import { SessionID } from "../session-id" import { SessionID } from "../session-id.js"
import { SessionV1 } from "./session" import { SessionV1 } from "./session.js"
export const ID = Schema.String.check(Schema.isStartsWith("que")).pipe( export const ID = Schema.String.check(Schema.isStartsWith("que")).pipe(
Schema.brand("QuestionID"), Schema.brand("QuestionID"),
+11 -11
View File
@@ -1,16 +1,16 @@
export * as SessionV1 from "./session" export * as SessionV1 from "./session.js"
import { Effect, Schema, Types } from "effect" import { Effect, Schema, Types } from "effect"
import { define, inventory } from "../event" import { define, inventory } from "../event.js"
import { FileDiff } from "../file-diff" import { FileDiff } from "../file-diff.js"
import { Project } from "../project" import { Project } from "../project.js"
import { Provider } from "../provider" import { Provider } from "../provider.js"
import { Model } from "../model" import { Model } from "../model.js"
import { NonNegativeInt, optional, statics } from "../schema" import { NonNegativeInt, optional, statics } from "../schema.js"
import { ascending } from "../identifier" import { ascending } from "../identifier.js"
import { SessionID } from "../session-id" import { SessionID } from "../session-id.js"
import { WorkspaceID } from "../workspace-id" import { WorkspaceID } from "../workspace-id.js"
import { PermissionV1 } from "./permission" import { PermissionV1 } from "./permission.js"
const Timestamp = Schema.Finite.check(Schema.isGreaterThanOrEqualTo(0)) const Timestamp = Schema.Finite.check(Schema.isGreaterThanOrEqualTo(0))
+3 -3
View File
@@ -1,8 +1,8 @@
export * as VcsEvent from "./vcs-event" export * as VcsEvent from "./vcs-event.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { Event } from "./event" import { Event } from "./event.js"
export const BranchUpdated = Event.define({ export const BranchUpdated = Event.define({
type: "vcs.branch.updated", type: "vcs.branch.updated",
+3 -3
View File
@@ -1,8 +1,8 @@
export * as WorkspaceEvent from "./workspace-event" export * as WorkspaceEvent from "./workspace-event.js"
import { Schema } from "effect" import { Schema } from "effect"
import { Event } from "./event" import { Event } from "./event.js"
import { WorkspaceID } from "./workspace-id" import { WorkspaceID } from "./workspace-id.js"
export const ConnectionStatus = Schema.Struct({ export const ConnectionStatus = Schema.Struct({
workspaceID: WorkspaceID, workspaceID: WorkspaceID,
+2 -2
View File
@@ -1,6 +1,6 @@
import { Schema } from "effect" import { Schema } from "effect"
import { ascending } from "./identifier" import { ascending } from "./identifier.js"
import { statics } from "./schema" import { statics } from "./schema.js"
export const WorkspaceID = Schema.String.check(Schema.isStartsWith("wrk")).pipe( export const WorkspaceID = Schema.String.check(Schema.isStartsWith("wrk")).pipe(
Schema.brand("WorkspaceV2.ID"), Schema.brand("WorkspaceV2.ID"),
+3 -3
View File
@@ -1,7 +1,7 @@
export * as Workspace from "./workspace" export * as Workspace from "./workspace.js"
import { WorkspaceEvent } from "./workspace-event" import { WorkspaceEvent } from "./workspace-event.js"
import { WorkspaceID } from "./workspace-id" import { WorkspaceID } from "./workspace-id.js"
export const ID = WorkspaceID export const ID = WorkspaceID
export type ID = WorkspaceID export type ID = WorkspaceID
+3 -3
View File
@@ -1,8 +1,8 @@
export * as WorktreeEvent from "./worktree-event" export * as WorktreeEvent from "./worktree-event.js"
import { Schema } from "effect" import { Schema } from "effect"
import { optional } from "./schema" import { optional } from "./schema.js"
import { Event } from "./event" import { Event } from "./event.js"
export const Ready = Event.define({ export const Ready = Event.define({
type: "worktree.ready", type: "worktree.ready",
+1 -1
View File
@@ -1,5 +1,5 @@
import { describe, expect, test } from "bun:test" import { describe, expect, test } from "bun:test"
import { FileSystem } from "../src/filesystem" import { FileSystem } from "../src/filesystem.js"
describe("schema compatibility", () => { describe("schema compatibility", () => {
test("moved class schemas remain constructible", () => { test("moved class schemas remain constructible", () => {
@@ -1,14 +1,14 @@
import { describe, expect, test } from "bun:test" import { describe, expect, test } from "bun:test"
import { Schema } from "effect" import { Schema } from "effect"
import { Agent } from "../src/agent" import { Agent } from "../src/agent.js"
import { FileSystem } from "../src/filesystem" import { FileSystem } from "../src/filesystem.js"
import { Model } from "../src/model" import { Model } from "../src/model.js"
import { Project } from "../src/project" import { Project } from "../src/project.js"
import { Pty } from "../src/pty" import { Pty } from "../src/pty.js"
import { Question } from "../src/question" import { Question } from "../src/question.js"
import { Session } from "../src/session" import { Session } from "../src/session.js"
import { SessionTodo } from "../src/session-todo" import { SessionTodo } from "../src/session-todo.js"
import { optional } from "../src/schema" import { optional } from "../src/schema.js"
describe("contract hygiene", () => { describe("contract hygiene", () => {
test("optional properties preserve transformations and omit undefined while encoding", () => { test("optional properties preserve transformations and omit undefined while encoding", () => {
+7 -7
View File
@@ -1,11 +1,11 @@
import { describe, expect, test } from "bun:test" import { describe, expect, test } from "bun:test"
import { Agent, FileSystem, Integration, Permission, Project, Reference, Session, Workspace } from "../src" import { Agent, FileSystem, Integration, Permission, Project, Reference, Session, Workspace } from "../src/index.js"
import { EventManifest } from "../src/event-manifest" import { EventManifest } from "../src/event-manifest.js"
import { IdeEvent } from "../src/ide-event" import { IdeEvent } from "../src/ide-event.js"
import { SessionEvent } from "../src/session-event" import { SessionEvent } from "../src/session-event.js"
import { SessionTodo } from "../src/session-todo" import { SessionTodo } from "../src/session-todo.js"
import { SessionV1 } from "../src/session-v1" import { SessionV1 } from "../src/session-v1.js"
import { WorkspaceEvent } from "../src/workspace-event" import { WorkspaceEvent } from "../src/workspace-event.js"
describe("public event manifest", () => { describe("public event manifest", () => {
test("owns the complete public event surface", () => { test("owns the complete public event surface", () => {
+1 -1
View File
@@ -1,6 +1,6 @@
import { describe, expect, test } from "bun:test" import { describe, expect, test } from "bun:test"
import { Schema } from "effect" import { Schema } from "effect"
import { Event } from "../src/event" import { Event } from "../src/event.js"
describe("public event schemas", () => { describe("public event schemas", () => {
test("definition is pure", () => { test("definition is pure", () => {
+5 -5
View File
@@ -1,9 +1,9 @@
import { describe, expect, test } from "bun:test" import { describe, expect, test } from "bun:test"
import { LegacyEvent } from "../src/legacy-event" import { LegacyEvent } from "../src/legacy-event.js"
import { PermissionV1 } from "../src/permission-v1" import { PermissionV1 } from "../src/permission-v1.js"
import { QuestionV1 } from "../src/question-v1" import { QuestionV1 } from "../src/question-v1.js"
import { Project } from "../src/project" import { Project } from "../src/project.js"
import { SessionV1 } from "../src/session-v1" import { SessionV1 } from "../src/session-v1.js"
describe("legacy public event schemas", () => { describe("legacy public event schemas", () => {
test("owns all SessionV1 definitions", () => { test("owns all SessionV1 definitions", () => {
+8 -8
View File
@@ -1,12 +1,12 @@
import { expect, test } from "bun:test" import { expect, test } from "bun:test"
import { LegacyEvent } from "../src/legacy-event" import { LegacyEvent } from "../src/legacy-event.js"
import { PermissionV1 } from "../src/permission-v1" import { PermissionV1 } from "../src/permission-v1.js"
import { QuestionV1 } from "../src/question-v1" import { QuestionV1 } from "../src/question-v1.js"
import { SessionV1 } from "../src/session-v1" import { SessionV1 } from "../src/session-v1.js"
import { LegacyEvent as IsolatedLegacyEvent } from "../src/v1/legacy-event" import { LegacyEvent as IsolatedLegacyEvent } from "../src/v1/legacy-event.js"
import { PermissionV1 as IsolatedPermissionV1 } from "../src/v1/permission" import { PermissionV1 as IsolatedPermissionV1 } from "../src/v1/permission.js"
import { QuestionV1 as IsolatedQuestionV1 } from "../src/v1/question" import { QuestionV1 as IsolatedQuestionV1 } from "../src/v1/question.js"
import { SessionV1 as IsolatedSessionV1 } from "../src/v1/session" import { SessionV1 as IsolatedSessionV1 } from "../src/v1/session.js"
test("compatibility entrypoints preserve isolated V1 schema identity", () => { test("compatibility entrypoints preserve isolated V1 schema identity", () => {
expect(LegacyEvent).toBe(IsolatedLegacyEvent) expect(LegacyEvent).toBe(IsolatedLegacyEvent)
+11
View File
@@ -0,0 +1,11 @@
{
"$schema": "https://json.schemastore.org/tsconfig",
"extends": "./tsconfig.json",
"compilerOptions": {
"rootDir": "src",
"outDir": "dist",
"noEmit": false,
"declaration": true
},
"include": ["src"]
}
+4
View File
@@ -3,6 +3,10 @@
"extends": "@tsconfig/bun/tsconfig.json", "extends": "@tsconfig/bun/tsconfig.json",
"compilerOptions": { "compilerOptions": {
"lib": ["ESNext", "DOM", "DOM.Iterable"], "lib": ["ESNext", "DOM", "DOM.Iterable"],
"module": "NodeNext",
"moduleResolution": "NodeNext",
"allowImportingTsExtensions": false,
"allowJs": false,
"noUncheckedIndexedAccess": false "noUncheckedIndexedAccess": false
} }
} }
+1
View File
@@ -1,6 +1,7 @@
{ {
"$schema": "https://json.schemastore.org/package", "$schema": "https://json.schemastore.org/package",
"name": "@opencode-ai/script", "name": "@opencode-ai/script",
"type": "module",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"semver": "^7.6.3" "semver": "^7.6.3"
+3
View File
@@ -35,6 +35,9 @@ if (Script.release && !Script.preview) {
await prepareReleaseFiles() await prepareReleaseFiles()
console.log("\n=== schema ===\n")
await $`bun ./packages/schema/script/publish.ts`
console.log("\n=== cli ===\n") console.log("\n=== cli ===\n")
await $`bun ./packages/cli/script/publish.ts` await $`bun ./packages/cli/script/publish.ts`