Skip to content

Add -Force parameter on any ConfirmImpact="High" cmdlets #218

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

Closed
TylerLeonhardt opened this issue Jun 2, 2020 · 3 comments · Fixed by #226
Closed

Add -Force parameter on any ConfirmImpact="High" cmdlets #218

TylerLeonhardt opened this issue Jun 2, 2020 · 3 comments · Fixed by #226
Labels
discussion We are looking for additional community feedback on this topic before proceeding further. enhancement An issue or pull request introducing new functionality to the project. in progress Work on this issue is already underway. Please don't work start new work on it.

Comments

@TylerLeonhardt
Copy link
Member

Feature Idea Summary

We should have a -Force to skip over confirmation since -Confirm:$false is tedious.

Feature Idea Additional Details

Take a look at @KevinMarquette's awesome blog post on implementing whatif/confirm/force:
https://powershellexplained.com/2020-03-15-Powershell-shouldprocess-whatif-confirm-shouldcontinue-everything/#implementing--force

Requested Assignment

I'm just suggesting this idea at this time.

@TylerLeonhardt TylerLeonhardt added enhancement An issue or pull request introducing new functionality to the project. triage needed An issue that needs to be reviewed by a member of the team. labels Jun 2, 2020
@HowardWolosky HowardWolosky added discussion We are looking for additional community feedback on this topic before proceeding further. good first issue If you're new to the project (or to OSS in general) and you'd like to contribute, try this one. help wanted Anyone in the community is welcome to do this work up for grabs Anyone in the community is welcome to do this work and removed triage needed An issue that needs to be reviewed by a member of the team. labels Jun 2, 2020
@HowardWolosky
Copy link
Contributor

I had brought this up initially when the idea was being introduced in #145. I think that doing this makes sense, as -Force was my natural instinct for how to avoid the prompting before learning about -Confirm:$false (which is why I've been enforcing having a -Confirm:$false example with every command that is ConfirmImpact='High'.

I like that by having both, there's the "standard" way that has built-in support by PowerShell, but also the more "natural" way that people might be inclined to initially try.

This wouldn't be a breaking change, so this seems reasonable for someone to tackle right away if they're interested.

@giuseppecampanelli
Copy link
Contributor

I'll tackle this 😄

@HowardWolosky
Copy link
Contributor

@themilanfan - it's yours. Thanks so much!

@HowardWolosky HowardWolosky added in progress Work on this issue is already underway. Please don't work start new work on it. and removed good first issue If you're new to the project (or to OSS in general) and you'd like to contribute, try this one. help wanted Anyone in the community is welcome to do this work up for grabs Anyone in the community is welcome to do this work labels Jun 3, 2020
HowardWolosky pushed a commit that referenced this issue Jun 10, 2020

Unverified

This user has not yet uploaded their public signing key.
Adding -Force switch to ConfirmImpact=High functions and updated affected tests/documentation

Fixes #218
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion We are looking for additional community feedback on this topic before proceeding further. enhancement An issue or pull request introducing new functionality to the project. in progress Work on this issue is already underway. Please don't work start new work on it.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants