mirror of
https://github.com/anomalyco/opencode.git
synced 2026-06-01 19:05:38 +00:00
chore: generate
This commit is contained in:
@@ -3,7 +3,9 @@ import { context } from "./instance-context"
|
|||||||
import { InstanceStore } from "./instance-store"
|
import { InstanceStore } from "./instance-store"
|
||||||
|
|
||||||
export async function provide<R>(input: { directory: string; fn: () => R }): Promise<R> {
|
export async function provide<R>(input: { directory: string; fn: () => R }): Promise<R> {
|
||||||
const ctx = await AppRuntime.runPromise(InstanceStore.Service.use((store) => store.load({ directory: input.directory })))
|
const ctx = await AppRuntime.runPromise(
|
||||||
|
InstanceStore.Service.use((store) => store.load({ directory: input.directory })),
|
||||||
|
)
|
||||||
return context.provide(ctx, () => input.fn())
|
return context.provide(ctx, () => input.fn())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -236,5 +236,4 @@ describe("InstanceStore", () => {
|
|||||||
expect(() => Instance.current).toThrow()
|
expect(() => Instance.current).toThrow()
|
||||||
}),
|
}),
|
||||||
)
|
)
|
||||||
|
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -4,35 +4,6 @@ export type ClientOptions = {
|
|||||||
baseUrl: `${string}://${string}` | (string & {})
|
baseUrl: `${string}://${string}` | (string & {})
|
||||||
}
|
}
|
||||||
|
|
||||||
export type Project = {
|
|
||||||
id: string
|
|
||||||
worktree: string
|
|
||||||
vcs?: "git"
|
|
||||||
name?: string
|
|
||||||
icon?: {
|
|
||||||
url?: string
|
|
||||||
override?: string
|
|
||||||
color?: string
|
|
||||||
}
|
|
||||||
commands?: {
|
|
||||||
/**
|
|
||||||
* Startup script to run when creating a new workspace (worktree)
|
|
||||||
*/
|
|
||||||
start?: string
|
|
||||||
}
|
|
||||||
time: {
|
|
||||||
created: number
|
|
||||||
updated: number
|
|
||||||
initialized?: number
|
|
||||||
}
|
|
||||||
sandboxes: Array<string>
|
|
||||||
}
|
|
||||||
|
|
||||||
export type EventProjectUpdated = {
|
|
||||||
type: "project.updated"
|
|
||||||
properties: Project
|
|
||||||
}
|
|
||||||
|
|
||||||
export type EventServerInstanceDisposed = {
|
export type EventServerInstanceDisposed = {
|
||||||
type: "server.instance.disposed"
|
type: "server.instance.disposed"
|
||||||
properties: {
|
properties: {
|
||||||
@@ -40,6 +11,21 @@ export type EventServerInstanceDisposed = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export type EventFileEdited = {
|
||||||
|
type: "file.edited"
|
||||||
|
properties: {
|
||||||
|
file: string
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export type EventFileWatcherUpdated = {
|
||||||
|
type: "file.watcher.updated"
|
||||||
|
properties: {
|
||||||
|
file: string
|
||||||
|
event: "add" | "change" | "unlink"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
export type EventLspClientDiagnostics = {
|
export type EventLspClientDiagnostics = {
|
||||||
type: "lsp.client.diagnostics"
|
type: "lsp.client.diagnostics"
|
||||||
properties: {
|
properties: {
|
||||||
@@ -201,53 +187,6 @@ export type EventInstallationUpdateAvailable = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export type EventWorkspaceReady = {
|
|
||||||
type: "workspace.ready"
|
|
||||||
properties: {
|
|
||||||
name: string
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
export type EventWorkspaceFailed = {
|
|
||||||
type: "workspace.failed"
|
|
||||||
properties: {
|
|
||||||
message: string
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
export type EventWorkspaceRestore = {
|
|
||||||
type: "workspace.restore"
|
|
||||||
properties: {
|
|
||||||
workspaceID: string
|
|
||||||
sessionID: string
|
|
||||||
total: number
|
|
||||||
step: number
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
export type EventWorkspaceStatus = {
|
|
||||||
type: "workspace.status"
|
|
||||||
properties: {
|
|
||||||
workspaceID: string
|
|
||||||
status: "connected" | "connecting" | "disconnected" | "error"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
export type EventFileEdited = {
|
|
||||||
type: "file.edited"
|
|
||||||
properties: {
|
|
||||||
file: string
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
export type EventFileWatcherUpdated = {
|
|
||||||
type: "file.watcher.updated"
|
|
||||||
properties: {
|
|
||||||
file: string
|
|
||||||
event: "add" | "change" | "unlink"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
export type QuestionOption = {
|
export type QuestionOption = {
|
||||||
/**
|
/**
|
||||||
* Display text (1-5 words, concise)
|
* Display text (1-5 words, concise)
|
||||||
@@ -463,6 +402,35 @@ export type EventCommandExecuted = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export type Project = {
|
||||||
|
id: string
|
||||||
|
worktree: string
|
||||||
|
vcs?: "git"
|
||||||
|
name?: string
|
||||||
|
icon?: {
|
||||||
|
url?: string
|
||||||
|
override?: string
|
||||||
|
color?: string
|
||||||
|
}
|
||||||
|
commands?: {
|
||||||
|
/**
|
||||||
|
* Startup script to run when creating a new workspace (worktree)
|
||||||
|
*/
|
||||||
|
start?: string
|
||||||
|
}
|
||||||
|
time: {
|
||||||
|
created: number
|
||||||
|
updated: number
|
||||||
|
initialized?: number
|
||||||
|
}
|
||||||
|
sandboxes: Array<string>
|
||||||
|
}
|
||||||
|
|
||||||
|
export type EventProjectUpdated = {
|
||||||
|
type: "project.updated"
|
||||||
|
properties: Project
|
||||||
|
}
|
||||||
|
|
||||||
export type EventVcsBranchUpdated = {
|
export type EventVcsBranchUpdated = {
|
||||||
type: "vcs.branch.updated"
|
type: "vcs.branch.updated"
|
||||||
properties: {
|
properties: {
|
||||||
@@ -470,6 +438,38 @@ export type EventVcsBranchUpdated = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export type EventWorkspaceReady = {
|
||||||
|
type: "workspace.ready"
|
||||||
|
properties: {
|
||||||
|
name: string
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export type EventWorkspaceFailed = {
|
||||||
|
type: "workspace.failed"
|
||||||
|
properties: {
|
||||||
|
message: string
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export type EventWorkspaceRestore = {
|
||||||
|
type: "workspace.restore"
|
||||||
|
properties: {
|
||||||
|
workspaceID: string
|
||||||
|
sessionID: string
|
||||||
|
total: number
|
||||||
|
step: number
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export type EventWorkspaceStatus = {
|
||||||
|
type: "workspace.status"
|
||||||
|
properties: {
|
||||||
|
workspaceID: string
|
||||||
|
status: "connected" | "connecting" | "disconnected" | "error"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
export type EventWorktreeReady = {
|
export type EventWorktreeReady = {
|
||||||
type: "worktree.ready"
|
type: "worktree.ready"
|
||||||
properties: {
|
properties: {
|
||||||
@@ -1111,8 +1111,9 @@ export type GlobalEvent = {
|
|||||||
project?: string
|
project?: string
|
||||||
workspace?: string
|
workspace?: string
|
||||||
payload:
|
payload:
|
||||||
| EventProjectUpdated
|
|
||||||
| EventServerInstanceDisposed
|
| EventServerInstanceDisposed
|
||||||
|
| EventFileEdited
|
||||||
|
| EventFileWatcherUpdated
|
||||||
| EventLspClientDiagnostics
|
| EventLspClientDiagnostics
|
||||||
| EventLspUpdated
|
| EventLspUpdated
|
||||||
| EventMessagePartDelta
|
| EventMessagePartDelta
|
||||||
@@ -1122,12 +1123,6 @@ export type GlobalEvent = {
|
|||||||
| EventSessionError
|
| EventSessionError
|
||||||
| EventInstallationUpdated
|
| EventInstallationUpdated
|
||||||
| EventInstallationUpdateAvailable
|
| EventInstallationUpdateAvailable
|
||||||
| EventWorkspaceReady
|
|
||||||
| EventWorkspaceFailed
|
|
||||||
| EventWorkspaceRestore
|
|
||||||
| EventWorkspaceStatus
|
|
||||||
| EventFileEdited
|
|
||||||
| EventFileWatcherUpdated
|
|
||||||
| EventQuestionAsked
|
| EventQuestionAsked
|
||||||
| EventQuestionReplied
|
| EventQuestionReplied
|
||||||
| EventQuestionRejected
|
| EventQuestionRejected
|
||||||
@@ -1142,7 +1137,12 @@ export type GlobalEvent = {
|
|||||||
| EventMcpToolsChanged
|
| EventMcpToolsChanged
|
||||||
| EventMcpBrowserOpenFailed
|
| EventMcpBrowserOpenFailed
|
||||||
| EventCommandExecuted
|
| EventCommandExecuted
|
||||||
|
| EventProjectUpdated
|
||||||
| EventVcsBranchUpdated
|
| EventVcsBranchUpdated
|
||||||
|
| EventWorkspaceReady
|
||||||
|
| EventWorkspaceFailed
|
||||||
|
| EventWorkspaceRestore
|
||||||
|
| EventWorkspaceStatus
|
||||||
| EventWorktreeReady
|
| EventWorktreeReady
|
||||||
| EventWorktreeFailed
|
| EventWorktreeFailed
|
||||||
| EventPtyCreated
|
| EventPtyCreated
|
||||||
@@ -2060,8 +2060,9 @@ export type File = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export type Event =
|
export type Event =
|
||||||
| EventProjectUpdated
|
|
||||||
| EventServerInstanceDisposed
|
| EventServerInstanceDisposed
|
||||||
|
| EventFileEdited
|
||||||
|
| EventFileWatcherUpdated
|
||||||
| EventLspClientDiagnostics
|
| EventLspClientDiagnostics
|
||||||
| EventLspUpdated
|
| EventLspUpdated
|
||||||
| EventMessagePartDelta
|
| EventMessagePartDelta
|
||||||
@@ -2071,12 +2072,6 @@ export type Event =
|
|||||||
| EventSessionError
|
| EventSessionError
|
||||||
| EventInstallationUpdated
|
| EventInstallationUpdated
|
||||||
| EventInstallationUpdateAvailable
|
| EventInstallationUpdateAvailable
|
||||||
| EventWorkspaceReady
|
|
||||||
| EventWorkspaceFailed
|
|
||||||
| EventWorkspaceRestore
|
|
||||||
| EventWorkspaceStatus
|
|
||||||
| EventFileEdited
|
|
||||||
| EventFileWatcherUpdated
|
|
||||||
| EventQuestionAsked
|
| EventQuestionAsked
|
||||||
| EventQuestionReplied
|
| EventQuestionReplied
|
||||||
| EventQuestionRejected
|
| EventQuestionRejected
|
||||||
@@ -2091,7 +2086,12 @@ export type Event =
|
|||||||
| EventMcpToolsChanged
|
| EventMcpToolsChanged
|
||||||
| EventMcpBrowserOpenFailed
|
| EventMcpBrowserOpenFailed
|
||||||
| EventCommandExecuted
|
| EventCommandExecuted
|
||||||
|
| EventProjectUpdated
|
||||||
| EventVcsBranchUpdated
|
| EventVcsBranchUpdated
|
||||||
|
| EventWorkspaceReady
|
||||||
|
| EventWorkspaceFailed
|
||||||
|
| EventWorkspaceRestore
|
||||||
|
| EventWorkspaceStatus
|
||||||
| EventWorktreeReady
|
| EventWorktreeReady
|
||||||
| EventWorktreeFailed
|
| EventWorktreeFailed
|
||||||
| EventPtyCreated
|
| EventPtyCreated
|
||||||
|
|||||||
@@ -7592,88 +7592,6 @@
|
|||||||
},
|
},
|
||||||
"components": {
|
"components": {
|
||||||
"schemas": {
|
"schemas": {
|
||||||
"Project": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"id": {
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"worktree": {
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"vcs": {
|
|
||||||
"type": "string",
|
|
||||||
"const": "git"
|
|
||||||
},
|
|
||||||
"name": {
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"icon": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"url": {
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"override": {
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"color": {
|
|
||||||
"type": "string"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"commands": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"start": {
|
|
||||||
"description": "Startup script to run when creating a new workspace (worktree)",
|
|
||||||
"type": "string"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"time": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"created": {
|
|
||||||
"type": "integer",
|
|
||||||
"minimum": 0,
|
|
||||||
"maximum": 9007199254740991
|
|
||||||
},
|
|
||||||
"updated": {
|
|
||||||
"type": "integer",
|
|
||||||
"minimum": 0,
|
|
||||||
"maximum": 9007199254740991
|
|
||||||
},
|
|
||||||
"initialized": {
|
|
||||||
"type": "integer",
|
|
||||||
"minimum": 0,
|
|
||||||
"maximum": 9007199254740991
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["created", "updated"]
|
|
||||||
},
|
|
||||||
"sandboxes": {
|
|
||||||
"type": "array",
|
|
||||||
"items": {
|
|
||||||
"type": "string"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["id", "worktree", "time", "sandboxes"]
|
|
||||||
},
|
|
||||||
"Event.project.updated": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"type": {
|
|
||||||
"type": "string",
|
|
||||||
"const": "project.updated"
|
|
||||||
},
|
|
||||||
"properties": {
|
|
||||||
"$ref": "#/components/schemas/Project"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["type", "properties"]
|
|
||||||
},
|
|
||||||
"Event.server.instance.disposed": {
|
"Event.server.instance.disposed": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
@@ -7693,6 +7611,48 @@
|
|||||||
},
|
},
|
||||||
"required": ["type", "properties"]
|
"required": ["type", "properties"]
|
||||||
},
|
},
|
||||||
|
"Event.file.edited": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
|
"type": "string",
|
||||||
|
"const": "file.edited"
|
||||||
|
},
|
||||||
|
"properties": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"file": {
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["file"]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["type", "properties"]
|
||||||
|
},
|
||||||
|
"Event.file.watcher.updated": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
|
"type": "string",
|
||||||
|
"const": "file.watcher.updated"
|
||||||
|
},
|
||||||
|
"properties": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"file": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"event": {
|
||||||
|
"type": "string",
|
||||||
|
"enum": ["add", "change", "unlink"]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["file", "event"]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["type", "properties"]
|
||||||
|
},
|
||||||
"Event.lsp.client.diagnostics": {
|
"Event.lsp.client.diagnostics": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
@@ -8155,144 +8115,6 @@
|
|||||||
},
|
},
|
||||||
"required": ["type", "properties"]
|
"required": ["type", "properties"]
|
||||||
},
|
},
|
||||||
"Event.workspace.ready": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"type": {
|
|
||||||
"type": "string",
|
|
||||||
"const": "workspace.ready"
|
|
||||||
},
|
|
||||||
"properties": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"name": {
|
|
||||||
"type": "string"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["name"]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["type", "properties"]
|
|
||||||
},
|
|
||||||
"Event.workspace.failed": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"type": {
|
|
||||||
"type": "string",
|
|
||||||
"const": "workspace.failed"
|
|
||||||
},
|
|
||||||
"properties": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"message": {
|
|
||||||
"type": "string"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["message"]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["type", "properties"]
|
|
||||||
},
|
|
||||||
"Event.workspace.restore": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"type": {
|
|
||||||
"type": "string",
|
|
||||||
"const": "workspace.restore"
|
|
||||||
},
|
|
||||||
"properties": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"workspaceID": {
|
|
||||||
"type": "string",
|
|
||||||
"pattern": "^wrk.*"
|
|
||||||
},
|
|
||||||
"sessionID": {
|
|
||||||
"type": "string",
|
|
||||||
"pattern": "^ses.*"
|
|
||||||
},
|
|
||||||
"total": {
|
|
||||||
"type": "integer",
|
|
||||||
"minimum": 0,
|
|
||||||
"maximum": 9007199254740991
|
|
||||||
},
|
|
||||||
"step": {
|
|
||||||
"type": "integer",
|
|
||||||
"minimum": 0,
|
|
||||||
"maximum": 9007199254740991
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["workspaceID", "sessionID", "total", "step"]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["type", "properties"]
|
|
||||||
},
|
|
||||||
"Event.workspace.status": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"type": {
|
|
||||||
"type": "string",
|
|
||||||
"const": "workspace.status"
|
|
||||||
},
|
|
||||||
"properties": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"workspaceID": {
|
|
||||||
"type": "string",
|
|
||||||
"pattern": "^wrk.*"
|
|
||||||
},
|
|
||||||
"status": {
|
|
||||||
"type": "string",
|
|
||||||
"enum": ["connected", "connecting", "disconnected", "error"]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["workspaceID", "status"]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["type", "properties"]
|
|
||||||
},
|
|
||||||
"Event.file.edited": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"type": {
|
|
||||||
"type": "string",
|
|
||||||
"const": "file.edited"
|
|
||||||
},
|
|
||||||
"properties": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"file": {
|
|
||||||
"type": "string"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["file"]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["type", "properties"]
|
|
||||||
},
|
|
||||||
"Event.file.watcher.updated": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"type": {
|
|
||||||
"type": "string",
|
|
||||||
"const": "file.watcher.updated"
|
|
||||||
},
|
|
||||||
"properties": {
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"file": {
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"event": {
|
|
||||||
"type": "string",
|
|
||||||
"enum": ["add", "change", "unlink"]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["file", "event"]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": ["type", "properties"]
|
|
||||||
},
|
|
||||||
"QuestionOption": {
|
"QuestionOption": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
@@ -8793,6 +8615,88 @@
|
|||||||
},
|
},
|
||||||
"required": ["type", "properties"]
|
"required": ["type", "properties"]
|
||||||
},
|
},
|
||||||
|
"Project": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"id": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"worktree": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"vcs": {
|
||||||
|
"type": "string",
|
||||||
|
"const": "git"
|
||||||
|
},
|
||||||
|
"name": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"icon": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"url": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"override": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"color": {
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"commands": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"start": {
|
||||||
|
"description": "Startup script to run when creating a new workspace (worktree)",
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"time": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"created": {
|
||||||
|
"type": "integer",
|
||||||
|
"minimum": 0,
|
||||||
|
"maximum": 9007199254740991
|
||||||
|
},
|
||||||
|
"updated": {
|
||||||
|
"type": "integer",
|
||||||
|
"minimum": 0,
|
||||||
|
"maximum": 9007199254740991
|
||||||
|
},
|
||||||
|
"initialized": {
|
||||||
|
"type": "integer",
|
||||||
|
"minimum": 0,
|
||||||
|
"maximum": 9007199254740991
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["created", "updated"]
|
||||||
|
},
|
||||||
|
"sandboxes": {
|
||||||
|
"type": "array",
|
||||||
|
"items": {
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["id", "worktree", "time", "sandboxes"]
|
||||||
|
},
|
||||||
|
"Event.project.updated": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
|
"type": "string",
|
||||||
|
"const": "project.updated"
|
||||||
|
},
|
||||||
|
"properties": {
|
||||||
|
"$ref": "#/components/schemas/Project"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["type", "properties"]
|
||||||
|
},
|
||||||
"Event.vcs.branch.updated": {
|
"Event.vcs.branch.updated": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
@@ -8811,6 +8715,102 @@
|
|||||||
},
|
},
|
||||||
"required": ["type", "properties"]
|
"required": ["type", "properties"]
|
||||||
},
|
},
|
||||||
|
"Event.workspace.ready": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
|
"type": "string",
|
||||||
|
"const": "workspace.ready"
|
||||||
|
},
|
||||||
|
"properties": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"name": {
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["name"]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["type", "properties"]
|
||||||
|
},
|
||||||
|
"Event.workspace.failed": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
|
"type": "string",
|
||||||
|
"const": "workspace.failed"
|
||||||
|
},
|
||||||
|
"properties": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"message": {
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["message"]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["type", "properties"]
|
||||||
|
},
|
||||||
|
"Event.workspace.restore": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
|
"type": "string",
|
||||||
|
"const": "workspace.restore"
|
||||||
|
},
|
||||||
|
"properties": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"workspaceID": {
|
||||||
|
"type": "string",
|
||||||
|
"pattern": "^wrk.*"
|
||||||
|
},
|
||||||
|
"sessionID": {
|
||||||
|
"type": "string",
|
||||||
|
"pattern": "^ses.*"
|
||||||
|
},
|
||||||
|
"total": {
|
||||||
|
"type": "integer",
|
||||||
|
"minimum": 0,
|
||||||
|
"maximum": 9007199254740991
|
||||||
|
},
|
||||||
|
"step": {
|
||||||
|
"type": "integer",
|
||||||
|
"minimum": 0,
|
||||||
|
"maximum": 9007199254740991
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["workspaceID", "sessionID", "total", "step"]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["type", "properties"]
|
||||||
|
},
|
||||||
|
"Event.workspace.status": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
|
"type": "string",
|
||||||
|
"const": "workspace.status"
|
||||||
|
},
|
||||||
|
"properties": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"workspaceID": {
|
||||||
|
"type": "string",
|
||||||
|
"pattern": "^wrk.*"
|
||||||
|
},
|
||||||
|
"status": {
|
||||||
|
"type": "string",
|
||||||
|
"enum": ["connected", "connecting", "disconnected", "error"]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["workspaceID", "status"]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": ["type", "properties"]
|
||||||
|
},
|
||||||
"Event.worktree.ready": {
|
"Event.worktree.ready": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
@@ -10958,10 +10958,13 @@
|
|||||||
"payload": {
|
"payload": {
|
||||||
"anyOf": [
|
"anyOf": [
|
||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.project.updated"
|
"$ref": "#/components/schemas/Event.server.instance.disposed"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.server.instance.disposed"
|
"$ref": "#/components/schemas/Event.file.edited"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/Event.file.watcher.updated"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.lsp.client.diagnostics"
|
"$ref": "#/components/schemas/Event.lsp.client.diagnostics"
|
||||||
@@ -10990,24 +10993,6 @@
|
|||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.installation.update-available"
|
"$ref": "#/components/schemas/Event.installation.update-available"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Event.workspace.ready"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Event.workspace.failed"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Event.workspace.restore"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Event.workspace.status"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Event.file.edited"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Event.file.watcher.updated"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.question.asked"
|
"$ref": "#/components/schemas/Event.question.asked"
|
||||||
},
|
},
|
||||||
@@ -11050,9 +11035,24 @@
|
|||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.command.executed"
|
"$ref": "#/components/schemas/Event.command.executed"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/Event.project.updated"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.vcs.branch.updated"
|
"$ref": "#/components/schemas/Event.vcs.branch.updated"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/Event.workspace.ready"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/Event.workspace.failed"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/Event.workspace.restore"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/Event.workspace.status"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.worktree.ready"
|
"$ref": "#/components/schemas/Event.worktree.ready"
|
||||||
},
|
},
|
||||||
@@ -13253,10 +13253,13 @@
|
|||||||
"Event": {
|
"Event": {
|
||||||
"anyOf": [
|
"anyOf": [
|
||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.project.updated"
|
"$ref": "#/components/schemas/Event.server.instance.disposed"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.server.instance.disposed"
|
"$ref": "#/components/schemas/Event.file.edited"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/Event.file.watcher.updated"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.lsp.client.diagnostics"
|
"$ref": "#/components/schemas/Event.lsp.client.diagnostics"
|
||||||
@@ -13285,24 +13288,6 @@
|
|||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.installation.update-available"
|
"$ref": "#/components/schemas/Event.installation.update-available"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Event.workspace.ready"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Event.workspace.failed"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Event.workspace.restore"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Event.workspace.status"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Event.file.edited"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Event.file.watcher.updated"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.question.asked"
|
"$ref": "#/components/schemas/Event.question.asked"
|
||||||
},
|
},
|
||||||
@@ -13345,9 +13330,24 @@
|
|||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.command.executed"
|
"$ref": "#/components/schemas/Event.command.executed"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/Event.project.updated"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.vcs.branch.updated"
|
"$ref": "#/components/schemas/Event.vcs.branch.updated"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/Event.workspace.ready"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/Event.workspace.failed"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/Event.workspace.restore"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/Event.workspace.status"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"$ref": "#/components/schemas/Event.worktree.ready"
|
"$ref": "#/components/schemas/Event.worktree.ready"
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user