Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/aws-cdk/lib/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,12 @@ export async function makeConfig(): Promise<CliConfig> {
'show-dependencies': { type: 'boolean', default: false, alias: 'd', desc: 'Display stack dependency information for each stack' },
},
},
synthesize: {
synth: {
arg: {
name: 'STACKS',
variadic: true,
},
aliases: ['synth'],
aliases: ['synthesize'],
description: 'Synthesizes and prints the CloudFormation template for this stack',
options: {
exclusively: { type: 'boolean', alias: 'e', desc: 'Only synthesize requested stacks, don\'t include dependencies' },
Expand Down
12 changes: 6 additions & 6 deletions packages/aws-cdk/lib/convert-to-user-input.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ export function convertYargsToUserInput(args: any): UserInput {
};
break;

case 'synthesize':
case 'synth':
case 'synthesize':
commandOptions = {
exclusively: args.exclusively,
validation: args.validation,
Expand Down Expand Up @@ -292,10 +292,10 @@ export function convertConfigToUserInput(config: any): UserInput {
long: config.list?.long,
showDependencies: config.list?.showDependencies,
};
const synthesizeOptions = {
exclusively: config.synthesize?.exclusively,
validation: config.synthesize?.validation,
quiet: config.synthesize?.quiet,
const synthOptions = {
exclusively: config.synth?.exclusively,
validation: config.synth?.validation,
quiet: config.synth?.quiet,
};
const bootstrapOptions = {
bootstrapBucketName: config.bootstrap?.bootstrapBucketName,
Expand Down Expand Up @@ -431,7 +431,7 @@ export function convertConfigToUserInput(config: any): UserInput {
const userInput: UserInput = {
globalOptions,
list: listOptions,
synthesize: synthesizeOptions,
synth: synthOptions,
bootstrap: bootstrapOptions,
gc: gcOptions,
deploy: deployOptions,
Expand Down
2 changes: 1 addition & 1 deletion packages/aws-cdk/lib/parse-command-line-arguments.ts
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ export function parseCommandLineArguments(args: Array<string>): any {
desc: 'Display stack dependency information for each stack',
}),
)
.command(['synthesize [STACKS..]', 'synth [STACKS..]'], 'Synthesizes and prints the CloudFormation template for this stack', (yargs: Argv) =>
.command(['synth [STACKS..]', 'synthesize [STACKS..]'], 'Synthesizes and prints the CloudFormation template for this stack', (yargs: Argv) =>
yargs
.option('exclusively', {
default: undefined,
Expand Down
10 changes: 5 additions & 5 deletions packages/aws-cdk/lib/user-input.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ export interface UserInput {
/**
* Synthesizes and prints the CloudFormation template for this stack
*
* aliases: synth
* aliases: synthesize
*/
readonly synthesize?: SynthesizeOptions;
readonly synth?: SynthOptions;

/**
* Deploys the CDK toolkit stack into an AWS environment
Expand Down Expand Up @@ -337,11 +337,11 @@ export interface ListOptions {
/**
* Synthesizes and prints the CloudFormation template for this stack
*
* aliases: synth
* aliases: synthesize
*
* @struct
*/
export interface SynthesizeOptions {
export interface SynthOptions {
/**
* Only synthesize requested stacks, don't include dependencies
*
Expand All @@ -368,7 +368,7 @@ export interface SynthesizeOptions {
readonly quiet?: boolean;

/**
* Positional argument for synthesize
* Positional argument for synth
*/
readonly STACKS?: Array<string>;
}
Expand Down
2 changes: 1 addition & 1 deletion packages/aws-cdk/test/cli-arguments.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ describe('config', () => {
metadata: expect.anything(),
migrate: expect.anything(),
rollback: expect.anything(),
synthesize: expect.anything(),
synth: expect.anything(),
watch: expect.anything(),
notices: expect.anything(),
import: expect.anything(),
Expand Down
Loading