import type { RuntimeAction } from '../engine/runtime-action.js'; import type { RunState } from '../engine/types.js'; import type { ClassicState } from './classic-state.js'; export type CommandCheckScope = 'build' | 'verify'; export interface RecordedCommandCheck { sequence: number; timestamp: string; runId: string; scope: CommandCheckScope; command: string; exitCode: number; cwd: string; provenance?: 'runtime' | 'agent'; argv?: string[]; timeoutMs?: number; inputBefore?: string; inputAfter?: string; /** Input paths whose contents changed during this execution. */ changedDuringExecution?: string[]; environment?: string; logRef?: string; logHash?: string; /** * Post-write stat of the evidence log. Revalidation trusts an unchanged * size+mtime instead of rereading the whole log; records without these * fields (or a changed stat) keep the full content-hash check. */ logSize?: number; logMtimeNs?: string; /** Repository-relative per-file input manifest recorded at execution time. */ manifestRef?: string; manifestHash?: string; /** Incremental evidence maintains validity inside a phase; only full evidence advances it. */ tier?: 'full' | 'incremental'; reusable?: boolean; reused?: boolean; checkEpoch?: number; action?: RuntimeAction; } export interface RecordCommandCheckInput { scope: CommandCheckScope; command: string; exitCode: number; cwd?: string; } export declare function recordCommandCheck(projectRoot: string, changeDir: string, run: RunState, input: RecordCommandCheckInput): Promise; export declare function rememberClassicAcceptedVerifyCheck(changeDir: string, run: RunState, state: ClassicState, check: RecordedCommandCheck): Promise; export declare function readClassicAcceptedVerifyCheck(changeDir: string, run: RunState, state: ClassicState): Promise<{ sequence: number; actionId: unknown; reportSha256: unknown; checkEpoch: number; manifestHash: string | null; candidateManifestRef: string | null; candidateManifestHash: string | null; bindingHash: string; }>; export declare function assertClassicAcceptedVerifyInputs(root: string, changeDir: string, run: RunState, state: ClassicState): Promise; export interface CommandCheckEvaluation { record: RecordedCommandCheck | null; /** Why the latest record is not reusable; absent when a record is usable or none exists. */ reason?: string; /** Added, removed and changed input paths relative to the recorded manifest. */ changedPaths?: string[]; /** The declared input scope that decided relevance for the changed paths. */ relevance?: string; /** * Neutral document paths that changed since execution while every material * input stayed identical; the record remains usable and these edits are * reported instead of silently dropped. */ documentChangesIgnored?: string[]; } export declare function latestCommandCheck(root: string, changeDir: string, run: RunState, scope: CommandCheckScope): Promise; export declare function evaluateCommandCheck(root: string, changeDir: string, run: RunState, scope: CommandCheckScope): Promise; //# sourceMappingURL=classic-command-checks.d.ts.map