/** * Where the vigiles integrity header sits in a file, and whether an * instruction file is under a spec — the node-free half of `integrity.ts`. * * Split out (like `assert-never.ts` from `hash.ts`) so the browser scan twin * can read these facts without `node:crypto`; `integrity.ts` re-exports all of * it, so callers import from there as before. */ /** * Split off a leading frontmatter block. `head` is `""` when the file has none, so a caller can * concatenate `head + body` unconditionally and get the original content back. */ export declare function splitFrontmatter(content: string): Readonly<{ head: string; body: string; }>; /** * Locate the integrity header wherever it legitimately sits — before the frontmatter (files * compiled before 2026-08-17) or after it (files compiled since). Returns the hash, the spec * path, and the content with the header removed and everything else intact. * * This is the ONLY place that knows where the header can be. Matching `/^"; /** * Whether an instruction file is under a spec, opted out of one, or neither. * * 🔴 THE ONE ANSWER to "is this instruction file hand-written?". `lint`'s * `require-instructions-spec`, `audit`'s adoption list and the scan's * `Instructions:` line each used to decide it with their own test — a sibling * spec only, a spec or a compiled header, with or without the marker — so the * same repo could be one hand-written file to `audit` and six to `lint`. * * - `spec-managed`: a sibling `.spec.ts`, or a compiled integrity header * (a multi-target file such as `AGENTS.md` compiled from `CLAUDE.md.spec.ts` * has no sibling spec and is still compiled); * - `opted-out`: the {@link REQUIRE_INSTRUCTIONS_SPEC_DISABLE} marker — kept * hand-written on purpose, and that decision is remembered; * - `hand-written`: neither. * * Pure: the caller says whether the sibling spec exists. */ export type InstructionSpecState = "spec-managed" | "opted-out" | "hand-written"; export declare function instructionSpecState(content: string, siblingSpecExists: boolean): InstructionSpecState; //# sourceMappingURL=integrity-header.d.ts.map