feat: add support for the --all flag to destroy#2271
feat: add support for the --all flag to destroy#2271benklop wants to merge 2 commits intocloudposse:mainfrom
Conversation
… corrects some slightly incorrect docs.
📝 WalkthroughWalkthroughThis pull request extends the Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested labels
Suggested reviewers
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
website/docs/cli/commands/terraform/terraform-destroy.mdx (1)
97-102:⚠️ Potential issue | 🟡 MinorClarify that
componentis not required for multi-component modes.The argument is marked as "(required)" but
--all,--affected,--components, and--querymodes don't require a positional component argument. This could confuse users.Suggested fix
<dl> - <dt>`component` <em>(required)</em></dt> + <dt>`component`</dt> <dd> - Atmos component name. + Atmos component name. Required for single-component destroys; omit when using `--all`, `--affected`, `--components`, or `--query`. </dd> </dl>🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@website/docs/cli/commands/terraform/terraform-destroy.mdx` around lines 97 - 102, The docs currently mark the `component` positional argument as "(required)" even though multi-component modes (`--all`, `--affected`, `--components`, `--query`) do not need it; update the description near the `component` term to clarify that `component` is required only for single-component mode and is optional/ignored when using `--all`, `--affected`, `--components`, or `--query`, and include a short note describing the behavior of those flags relative to `component`.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Outside diff comments:
In `@website/docs/cli/commands/terraform/terraform-destroy.mdx`:
- Around line 97-102: The docs currently mark the `component` positional
argument as "(required)" even though multi-component modes (`--all`,
`--affected`, `--components`, `--query`) do not need it; update the description
near the `component` term to clarify that `component` is required only for
single-component mode and is optional/ignored when using `--all`, `--affected`,
`--components`, or `--query`, and include a short note describing the behavior
of those flags relative to `component`.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: fe5db488-c912-4a83-b64c-c487940418ca
📒 Files selected for processing (3)
cmd/terraform/destroy.gocmd/terraform/destroy_test.gowebsite/docs/cli/commands/terraform/terraform-destroy.mdx
what
add flag support (like --all) to the destroy command, to allow destroy to tear down a stack using dependency ordering (once that's working properly).
why
Especially while testing new features that use lots of various terraform components, it's useful to be able to deploy, test, then destroy entire stacks at once.
references
Summary by CodeRabbit
Release Notes
New Features
--affectedflag to destroy affected components--allflag to destroy all components in a stackDocumentation