UNPKG

@struktoai/mirage-core

Version:

A Unified Virtual Filesystem For AI Agents

25 lines • 1.62 kB
import { type ByteSource } from '../../../../../io/types.ts'; import { type PathSpec } from '../../../../../types.ts'; import type { FlagValue } from '../../../../spec/types.ts'; import { type CrossResult, type DispatchFn, type OperandRun, type RunSingle } from '../types.ts'; import type { Files } from '../../../../../workspace/files.ts'; /** * The run as counted, recounting it through the dispatcher if needed. A * mount's wc that succeeds without counts (one not built on the generic) * leaves its operand to the generic over the dispatcher, and only that * operand: the others keep what their own mount counted. Mirrors Python's * recount. */ export declare function recount(run: OperandRun, bag: Record<string, FlagValue>, dispatch: DispatchFn, cwd: string, vfs: Files | undefined, stdin: ByteSource | null): Promise<OperandRun>; /** * Count each operand on its own mount and lay the rows out together. Each * operand runs through its owning mount's wc, so a mount that counts without * reading its file (a database row count) still does, and reading mounts * stream. Only the layout spans the line: the counts each run reports * (`IOResult.records`) go through the generic's formatter with GNU's * column width, and no mount's output text is read back. A run that succeeds * without counts is recounted on its own (`recount`). Mirrors Python's * run_wc. */ export declare function runWc(scopes: PathSpec[], flagKwargs: Record<string, FlagValue>, dispatch: DispatchFn, runSingle: RunSingle, cwd?: string, vfs?: Files, stdin?: ByteSource | null): Promise<CrossResult>; //# sourceMappingURL=wc.d.ts.map