import { CommandLineParser } from '@rushstack/ts-command-line'; import { type ITerminal, type ITerminalProvider } from '@rushstack/terminal'; import { RushConfiguration } from '../api/RushConfiguration'; import { Telemetry } from '../logic/Telemetry'; import { RushGlobalFolder } from '../api/RushGlobalFolder'; import { PluginManager } from '../pluginFramework/PluginManager'; import { type IRushSessionReporterOptions, RushSession } from '../pluginFramework/RushSession'; import type { IBuiltInPluginConfiguration } from '../pluginFramework/PluginLoader/BuiltInPluginLoader'; import type { StandardOutputClosure } from '../utilities/StandardOutputClosure'; import { type IRepositoryLockWait } from '../logic/RepositoryLockWait'; /** * Options for `RushCommandLineParser`. */ export interface IRushCommandLineParserOptions { cwd: string; alreadyReportedNodeTooNewError: boolean; builtInPluginConfigurations: IBuiltInPluginConfiguration[]; reporter?: IRushSessionReporterOptions; reporterCloseAsync?: () => Promise; /** * Reports that a reader of the process's stdout or stderr exited, for example `head` in `rush build | head -5`. * Only the Rush CLI supplies it; see {@link RushCommandLineParser.standardOutputClosure}. */ standardOutputClosure?: StandardOutputClosure; /** Parse native commands without executing CLI actions or initializing process-global state. */ engine?: { rushConfiguration: RushConfiguration; terminalProvider: ITerminalProvider; /** The environment of the request; see {@link RushCommandLineParser.engineEnvironment}. */ environment?: Readonly>; }; } export declare class RushCommandLineParser extends CommandLineParser { #private; telemetry: Telemetry | undefined; rushGlobalFolder: RushGlobalFolder; readonly rushConfiguration: RushConfiguration; readonly rushSession: RushSession; readonly pluginManager: PluginManager; /** * The wait for the repository lock that `rush-client` asked for when it ran this command in-process after it tried * the Rush daemon. A parser that serves an engine host never has one. */ readonly repositoryLockWait: IRepositoryLockWait | undefined; /** * The current working directory that was used to find the Rush configuration. */ get cwd(): string; /** * For a parser that serves a long-lived engine host, the environment of the request being parsed. Actions read * environment-backed parameter defaults from it instead of from `process.env`. */ get engineEnvironment(): Readonly> | undefined; /** * For the Rush CLI, reports that a reader of the process's stdout or stderr exited. A phased command then stops * starting operations. Undefined for the automation API and for a parser that serves an engine host. */ get standardOutputClosure(): StandardOutputClosure | undefined; constructor(options?: Partial); get isDebug(): boolean; get isQuiet(): boolean; get terminal(): ITerminal; /** * Utility to determine if the app should restrict writing to the console. */ static shouldRestrictConsoleOutput(): boolean; flushTelemetry(): void; executeAsync(args?: string[]): Promise; executeWithoutErrorHandlingAsync(args?: string[]): Promise; protected onExecuteAsync(): Promise; } //# sourceMappingURL=RushCommandLineParser.d.ts.map