/** * no-root-pollution enforcer — PreToolUse Write/Edit guard. * * Per L2 redesign §5.4. Deny writes to /root for files NOT in * the documented allowlist. The allowlist is hand-maintained for v1; a * follow-up slice can expose it via `peaks standards`. * * Trust red line: this hook MUST fail-open on registry / FS errors. The * LLM is never bricked by a peaks bug. */ export interface RootWriteCheckInput { readonly projectRoot: string; readonly filePath: string; } export interface RootWriteCheckResult { readonly isRoot: boolean; readonly allowed: boolean; readonly topSegment: string; readonly denyReason: string; } export declare function isRootWrite(input: RootWriteCheckInput): RootWriteCheckResult;