wip: replace packages with pure files

This commit is contained in:
Justin Lin committed 2025-04-24 23:20:40 +08:00
1 parent 2d95ca382f
commit 87b8ca5d04
112 files changed
+740 -522

No files matched your search

+23
View File
@@ -0,0 +1,23 @@
import { z } from 'zod'
const fileSchema = z.object({
path: z.string(),
type: z.enum(['file', 'directory']),
discovered: z.boolean(),
})
export const commandParamsSchema = z.object({
discover: fileSchema.array().optional(),
})
export type ICommandParams = z.infer<typeof commandParamsSchema>
export const commandSchema = z.object({
command: z.string().optional(),
output: z.string().optional(),
error: z.string().optional(),
pwd: z.string().optional(),
params: commandParamsSchema.optional(),
})
export type ICommand = z.infer<typeof commandSchema>