import type { Policy } from './types.js'; export { checkCommand, extractFileTargets } from './compiler/commands.js'; /** * Normalize a path for cross-platform pattern matching. * - Converts backslashes to forward slashes (Windows paths) * - Removes trailing slashes * - Normalizes . and .. segments */ export declare function normalizePath(p: string): string; /** * Check if a target path is protected by the policy. * Returns true if the target matches include patterns and doesn't match exclude patterns. */ export declare function isProtected(target: string, policy: Policy): boolean; /** * Get all files in a list that would be protected by the policy. */ export declare function getProtectedFiles(files: string[], policy: Policy): string[]; /** * Get all files in a list that would be excluded (allowed) by the policy. */ export declare function getExcludedFiles(files: string[], policy: Policy): string[]; /** * Full policy check for a bash command. * Checks both file targets (for delete/modify actions) and command rules. */ export declare function checkBashCommand(command: string, policy: Policy): { allowed: boolean; reason?: string; suggest?: string; }; /** * Check if a policy has any command rules. */ export declare function hasCommandRules(policy: Policy): boolean; /** * Check if a policy is command-only (no file patterns). */ export declare function isCommandOnlyPolicy(policy: Policy): boolean; //# sourceMappingURL=matcher.d.ts.map