import type { CommandCheckResult, Policy } from '../types.js'; /** * Split a complex command string into individual commands. * Handles: &&, ||, ;, |, and subshells */ export declare function splitCommands(fullCommand: string): string[]; /** * Normalize a command for pattern matching. * - Lowercase * - Collapse whitespace * - Trim */ export declare function normalizeCommand(command: string): string; /** * Check if a command matches a pattern. * Patterns use glob-style matching: * - "npm install" - exact match or prefix * - "npm *" - npm with any subcommand * - "npm install *" - npm install with any args * - "*lodash*" - any command containing lodash */ export declare function commandMatches(command: string, pattern: string): boolean; /** * Check a command string against all command rules in a policy. * Returns the first matching rule, or null if allowed. */ export declare function checkCommand(command: string, policy: Policy): CommandCheckResult; /** * Check a command against multiple policies. * Returns the first blocking result. */ export declare function checkCommandAgainstPolicies(command: string, policies: Policy[]): CommandCheckResult & { policy?: Policy; }; /** * Extract file targets from common shell commands. * Used for file-level policy checking on bash commands. */ export declare function extractFileTargets(command: string, action: 'delete' | 'modify' | 'execute' | 'read'): string[]; //# sourceMappingURL=commands.d.ts.map