Fix TypeScript compilation errors and consolidate version handling

🤖 Generated with [opencode](https://opencode.ai)

Co-Authored-By: opencode <noreply@opencode.ai>
This commit is contained in:
Dax Raad
2025-06-17 10:27:49 -04:00
parent 2d68814abc
commit 68e1b3c46c
15 changed files with 123 additions and 181 deletions

View File

@@ -2,10 +2,24 @@ import path from "path"
import { $ } from "bun"
import { z } from "zod"
import { NamedError } from "../util/error"
import { Bus } from "../bus"
declare global {
const OPENCODE_VERSION: string
}
export namespace Installation {
export type Method = Awaited<ReturnType<typeof method>>
export const Event = {
Updated: Bus.event(
"installation.updated",
z.object({
version: z.string(),
}),
),
}
export const Info = z
.object({
version: z.string(),