Skip to content
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

added --all option to remove #2341

Closed
wants to merge 2 commits into from

Conversation

rschwarzkopf
Copy link

Pull Request Check List

Resolves: #1884 (not really, but it implements a proposal made by @finswimmer)

  • Added tests for changed code.
  • Updated documentation for changed code.

I tried to base this PR on develop, but the tests do not run at all in that branch, so I based it on master although it introduces a new feature.

I added an --all option to env remove to remove all environments at once. The idea to use an option is also taken from the issue. Of the two variants, I prefer the option because it does not break the existing cli.

On the other hand, this approach requires a little workaround, because the python argument to env remove needs to be optional for --all to work, but without the --all option it is a required argument. I'm manually throwing an exception if neither --all nor an argument are given - in fact I throw the exception CliKit would have thrown in that case. I added an additional test just for this case.

Maybe it would be best to add a complete new subcommand for this. I just had no good idea how to name it. Maybe remove-all, but I wasn't sure if you like dashes in commands. So if anyone has a good idea I happily adopt my PR.

@finswimmer finswimmer added the kind/feature Feature requests/implementations label Apr 24, 2020
@neersighted
Copy link
Member

#3212 was landed which implements this. Thanks for your PR!

Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 29, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
kind/feature Feature requests/implementations
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CLI command to remove all old environments
3 participants