CLI: Rename delete command to remove, add 'rm' alias#14399
Open
dkbennett wants to merge 1 commit intofeature/wsl-for-appsfrom
Open
CLI: Rename delete command to remove, add 'rm' alias#14399dkbennett wants to merge 1 commit intofeature/wsl-for-appsfrom
dkbennett wants to merge 1 commit intofeature/wsl-for-appsfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the WSLC CLI container deletion UX by renaming the delete command to remove and adding a Docker-like rm alias, with corresponding task and test updates.
Changes:
- Rename
container delete/deletetocontainer remove/remove. - Add
rmas an alias for theremovecommand (includingcontainer rm). - Update unit/E2E tests and task wiring to reflect the new command name.
Reviewed changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| test/windows/wslc/e2e/WSLCE2EHelpers.cpp | Update cleanup helper to invoke container remove instead of container delete. |
| test/windows/wslc/e2e/WSLCE2EGlobalTests.cpp | Update expected root help output to list remove instead of delete. |
| test/windows/wslc/e2e/WSLCE2EContainerTests.cpp | Update expected container subcommand help output to list remove instead of delete. |
| test/windows/wslc/CommandLineTestCases.h | Update parsing test cases to expect remove and accept rm alias forms. |
| src/windows/wslc/tasks/ContainerTasks.h | Rename task declaration from DeleteContainers to RemoveContainers. |
| src/windows/wslc/tasks/ContainerTasks.cpp | Rename/relocate implementation to RemoveContainers while keeping deletion behavior. |
| src/windows/wslc/commands/RootCommand.cpp | Replace registration of ContainerDeleteCommand with ContainerRemoveCommand. |
| src/windows/wslc/commands/ContainerRemoveCommand.cpp | Implement remove command execution and descriptions. |
| src/windows/wslc/commands/ContainerCommand.h | Replace ContainerDeleteCommand with ContainerRemoveCommand and add rm alias. |
| src/windows/wslc/commands/ContainerCommand.cpp | Replace ContainerDeleteCommand registration with ContainerRemoveCommand. |
Comments suppressed due to low confidence (1)
src/windows/wslc/commands/ContainerRemoveCommand.cpp:32
ArgType::Forceis included forremove, but its default description (fromArgumentDefinitions.h) still says "Delete containers even if they are running". This will makewslc (container) remove --helpshow outdated wording. Consider overriding the description in this command (viaArgument::Create(..., desc=...)) or updating the sharedArgType::Forcedescription to use “Remove” wording.
You can also share your feedback on Copilot code review. Take the survey.
yao-msft
approved these changes
Mar 10, 2026
OneBlue
approved these changes
Mar 10, 2026
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.
Summary of the Pull Request
Renames the "delete" command to "remove"
Adds the "rm" alias for this command
Renames the associated task as well, and updates tests.
PR Checklist
Detailed Description of the Pull Request / Additional comments
Entire PR is just renaming and adding the "rm" alias to the command.
The diff might be a bit off because I am preserving alphabetical ordering in the tasks so that may cause it to look like there's new functions but it's just a rename.
Validation Steps Performed
Ran updated unit and E2E tests and all pass. Verified command is also functioning as "remove" or "rm"