Open adamdriscoll opened 4 years ago
oh, great use case - and very PowerShell'ey!
MUCH more important than Get-Credential
itself is - to us at least - the support of [PSCredential]
parameter types.
The majority of our scripts have to do something on one or more remote systems, so they all have a parameter like this:
Param (
[Parameter ( Mandatory = $true )]
[PSCredential]$Credential
)
and UA unfortunately only prompts for a simple string, and the script fails.
In an existing powershell automation solution we use, PSCredential
parameters are automatically recognized and when you want to run the script a dropdown of credentials you've configured before is available to choose from. I think that is the ideal approach.
Thanks for the feedback! I think making the parameter input more useful should be something we focus on sooner than later.
It would be neat to support Get-Credential. It would just be feedback requested and then you would end a credential so the script could continue.