Skip to content

docs(cli): document what --unstable means for cdk gc #32013

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Nov 4, 2024
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
5 changes: 4 additions & 1 deletion packages/aws-cdk/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -895,7 +895,10 @@ cdk bootstrap --no-previous-parameters
CDK Garbage Collection.

> [!CAUTION]
> CDK Garbage Collection is under development and therefore must be opted in via the `--unstable` flag: `cdk gc --unstable=gc`.
> CDK Garbage Collection is under development and therefore must be opted in via the
>`--unstable` flag: `cdk gc --unstable=gc`. `--unstable` indicates that the scope and
> API of feature might still change. Otherwise the feature is generally production
> ready and fully supported.
`cdk gc` garbage collects unused assets from your bootstrap bucket via the following mechanism:

Expand Down
2 changes: 1 addition & 1 deletion packages/aws-cdk/lib/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ async function parseCommandLineArguments(args: string[]) {
.option('template', { type: 'string', requiresArg: true, desc: 'Use the template from the given file instead of the built-in one (use --show-template to obtain an example)' })
.option('previous-parameters', { type: 'boolean', default: true, desc: 'Use previous values for existing parameters (you must specify all parameters on every deployment if this is disabled)' }),
)
.command('gc [ENVIRONMENTS..]', 'Garbage collect assets', (yargs: Argv) => yargs
.command('gc [ENVIRONMENTS..]', 'Garbage collect assets. Options detailed here: https://github.com/aws/aws-cdk/blob/main/packages/aws-cdk/README.md#cdk-gc', (yargs: Argv) => yargs
.option('action', { type: 'string', desc: 'The action (or sub-action) you want to perform. Valid entires are "print", "tag", "delete-tagged", "full".', default: 'full' })
.option('type', { type: 'string', desc: 'Specify either ecr, s3, or all', default: 'all' })
.option('rollback-buffer-days', { type: 'number', desc: 'Delete assets that have been marked as isolated for this many days', default: 0 })
Expand Down
Loading