export interface ParsedCommand { /** The main command to execute (without environment variables) */ command: string; /** Environment variables set for this command */ envVars: Record; /** Arguments passed to the command */ args: string[]; /** The full command line as a string */ fullCommand: string; } /** * Parse a shell command to extract the actual command, args, and environment variables. * Uses simple regex-based parsing to handle common cases like: * * - `pnpm build` * - `NODE_ENV=production webpack --mode production` * - `KEY1=value1 KEY2=value2 command arg1 arg2` * * @example * parseShellCommand('NODE_ENV=production webpack --mode production'); * // Returns: { command: 'webpack', envVars: { NODE_ENV: 'production' }, args: ['--mode', 'production'] } * * @example * parseShellCommand('pnpm build'); * // Returns: { command: 'pnpm', envVars: {}, args: ['build'] } */ export declare function parseShellCommand(commandLine: string): ParsedCommand; /** * Split a command line into multiple commands based on shell operators (;, &&) Respects * quotes and escapes. * * @example * splitCommands('npm run build && npm run test'); * // Returns: ['npm run build', 'npm run test'] * * @example * splitCommands('echo "hello; world" && npm run build'); * // Returns: ['echo "hello; world"', 'npm run build'] */ export declare function splitCommands(commandLine: string): string[];