diff --git a/Types/Namespace/get_Function.ps1 b/Types/Namespace/get_Function.ps1 new file mode 100644 index 000000000..d5d050cf8 --- /dev/null +++ b/Types/Namespace/get_Function.ps1 @@ -0,0 +1,7 @@ +if (-not $this.Pattern) { return } +if (-not $global:AllFunctionsOrFilters) { + $global:AllFunctionsOrFilters = $global:ExecutionContext.SessionState.InvokeCommand.GetCommands('*','Function,Filter',$true) +} +foreach ($cmdPattern in $this.Pattern) { + $global:AllFunctionsOrFilters -match $cmdPattern +} \ No newline at end of file