UNPKG

aws-cdk

Version:

AWS CDK CLI, the command line tool for CDK apps

32 lines (31 loc) 1.42 kB
export { isCI } from '../util/ci'; /** * yargs middleware to negate an option if a negative alias is provided * E.g. `-R` will imply `--rollback=false` * * @param optionToNegate - The name of the option to negate, e.g. `rollback` * @param negativeAlias - The alias that should negate the option, e.g. `R` * @returns a middleware function that can be passed to yargs */ export declare function yargsNegativeAlias<T extends { [x in S | L]: boolean | undefined; }, S extends string, L extends string>(negativeAlias: S, optionToNegate: L): (argv: T) => T; /** * yargs middleware to switch on other boolean options when a flag is set. * E.g. `--debug` implies `--debug-app` and `--debug-cli`. * * @param flag - The camelCase name of the flag that implies the others, e.g. `debug` * @param impliedOptions - The camelCase names of the options to switch on, e.g. `['debugApp', 'debugCli']` * @returns a middleware function that can be passed to yargs */ export declare function yargsImplies(flag: string, impliedOptions: string[]): (argv: Record<string, any>) => Record<string, any>; /** * Returns the current version of the CLI * @returns the current version of the CLI */ export declare function cliVersion(): string; /** * Returns the default browser command for the current platform * @returns the default browser command for the current platform */ export declare function browserForPlatform(): string;