mirror of
https://github.com/stablyai/orca.git
synced 2026-09-23 00:02:29 +00:00
* fix(quality): clear safe existing lint findings * fix(quality): keep lint cleanup allocation-free * fix(quality): enforce performance-safe baseline * test(terminal): drain deferred confirmation cleanup
19 lines
576 B
TypeScript
19 lines
576 B
TypeScript
export type CommandSpec = {
|
|
path: string[]
|
|
// Why: conventional alternate verbs should resolve without duplicating specs or handlers.
|
|
aliases?: string[][]
|
|
argumentMode?: 'parsed' | 'passthrough'
|
|
// Why: typo recovery must never steer a benign mistake into destructive state changes.
|
|
destructive?: boolean
|
|
summary: string
|
|
usage: string
|
|
allowedFlags: string[]
|
|
positionalArgs?: string[]
|
|
examples?: string[]
|
|
notes?: string[]
|
|
}
|
|
|
|
export function specPaths(spec: CommandSpec): string[][] {
|
|
return spec.aliases ? [spec.path, ...spec.aliases] : [spec.path]
|
|
}
|