Skip to content

v1.3.0

Latest

Choose a tag to compare

@santisq santisq released this 28 Jul 21:45
· 1 commit to main since this release
fe15f4d

What's Changed

Features & Enhancements

  • Wildcard support for -Variables and -Functions: Both parameters now accept string patterns with wildcards (e.g., *, foo*, [ab]*) to dynamically import matching items from the caller's scope into the parallel scope.
    • Example: -Variables * imports all non-built-in variables, or -Variables foo* imports only variables starting with foo.
    • Example: -Functions Get-* defines all Get- functions in the parallel scope.

Note

When resolving variables via string patterns, variables whose values are of type ScriptBlock are silently ignored. Explicitly passing script blocks via hashtable like -Variables @{ foo = { ... } } retains its existing behavior.

  • Support for multiple dictionaries in -Variables: Updated parameter type from Hashtable to IDictionary[], allowing multiple dictionaries to be passed as arguments. Duplicate keys are automatically ignored.

Behavior & Breaking Changes

  • Terminating error for unmatched variables: -Variables now throws a terminating error (ItemNotFoundException) if a specified variable name or wildcard pattern fails to match any variable in the caller's scope (aligning with the existing behavior of -Functions).

Refactoring

  • Major internal refactoring to simplify code structure and improve overall readability.

Full Changelog: v1.2.5...v1.3.0