I am using CTP3 and trying to figure out if i can change the default
of ShouldProcess to be No rather than Yes
With this function
function test {
[CmdletBinding(SupportsShouldProcess=$true,ConfirmImpact="High")]
param
([Parameter( Mandatory=$true)]$thing)
if ($pscmdlet.ShouldProcess($thing,"Destroy")) {"Destroyed $thing"}
}
I get prompted as shown below.
PS C:\> test
cmdlet test at command pipeline position 1
Supply values for the following parameters:
thing: something
Confirm
Are you sure you want to perform this action?
Performing operation "Destroy" on Target "something".
[Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help
(default is "Y"): N
PS C:\>
but what I would really like is to have the default button be "no"
rather than "Yes"


