Mending Broken Windows #2
Editor, no Remove-Alias before PowrShell Core. IValidateSetValuesGenerator missing before PowerShell Core
This commit is contained in:
parent
586f187346
commit
607fff132f
4 changed files with 21 additions and 6 deletions
|
@ -1,4 +1,4 @@
|
|||
class FunctionName: System.Management.Automation.IValidateSetValuesGenerator {
|
||||
class FunctionName { #: System.Management.Automation.IValidateSetValuesGenerator {
|
||||
static [string[]] _GetValidValues([string]$wordToComplete,[bool]$Strict) {
|
||||
$local:possibleValues = Get-Command -Type Function | Select-Object -ExpandProperty Name
|
||||
return $(Get-PossibleArguments -WordToComplete $wordToComplete -FullValueSet $possibleValues -Strict:$Strict );
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
class MyScript : System.Management.Automation.IValidateSetValuesGenerator {
|
||||
class MyScript { #: System.Management.Automation.IValidateSetValuesGenerator {
|
||||
static [string[]] _GetValidValues([string]$wordToComplete,[bool]$Strict) {
|
||||
$local:possibleValues = $(
|
||||
Get-ChildItem $global:MyPSScriptRoot -Filter '*.ps1' -Recurse |
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue