feat(remove): add remove command to remove a service from azure.yaml#511
Open
jongio wants to merge 1 commit into
Open
feat(remove): add remove command to remove a service from azure.yaml#511jongio wants to merge 1 commit into
jongio wants to merge 1 commit into
Conversation
Add `azd app remove <service>` as the inverse of `azd app add`. It deletes the named service from the services section of azure.yaml and preserves every other service and top-level key. Removing a service that is not present fails and lists the current service names. Supports the global --output json flag. Closes #506 Co-authored-by: Copilot App <[email protected]>
Contributor
|
🚀 Website Preview Your PR preview is ready! 📎 Preview URL: https://jongio.github.io/azd-app/pr/511/ This preview will be automatically cleaned up when the PR is closed. |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #511 +/- ##
==========================================
- Coverage 60.77% 60.72% -0.06%
==========================================
Files 223 224 +1
Lines 28527 28611 +84
==========================================
+ Hits 17337 17373 +36
- Misses 10010 10052 +42
- Partials 1180 1186 +6
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
Contributor
🚀 Test This PRA preview build ( 🌐 Website PreviewLive Preview: https://jongio.github.io/azd-app/pr/511/ One-Line Install (Recommended)PowerShell (Windows): iex "& { $(irm https://raw.githubusercontent.com/jongio/azd-app/main/cli/scripts/install-pr.ps1) } -PrNumber 511 -Version 0.19.5-pr511"Bash (macOS/Linux): curl -fsSL https://raw.githubusercontent.com/jongio/azd-app/main/cli/scripts/install-pr.sh | bash -s 511 0.19.5-pr511UninstallWhen you're done testing: PowerShell (Windows): iex "& { $(irm https://raw.githubusercontent.com/jongio/azd-app/main/cli/scripts/uninstall-pr.ps1) } -PrNumber 511"Bash (macOS/Linux): curl -fsSL https://raw.githubusercontent.com/jongio/azd-app/main/cli/scripts/uninstall-pr.sh | bash -s 511Build Info:
What to Test: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds
azd app remove <service>, the inverse ofazd app add. It deletes the named service from theservicessection of azure.yaml and leaves every other service and top-level key untouched.Why
addwrites a service into azure.yaml but there was no matching command to take one back out. Undoing an add meant hand-editing YAML and finding the right entry. This closes that gap so the add/remove pair is symmetric.Behavior
azd app remove redisdeletes the redis entry and preserves the rest of the file--output jsonflagTests
Table-driven unit tests cover a successful removal (with sibling and top-level preservation), an unknown service, a missing services section, the not-found message, JSON result shape, and the no-argument error.
Closes #506