Pimp Your Parameters: The Magic of PowerShell Argument..
summary
Explains how actual PowerShell argument completers are implemented and demoed: static ValidateSet and enum examples, dynamic completers that list services and processes, a REST-backed dog‑breed and country completer that breaks when the API is down, and an Octopus Deploy module with ~80 functions wired to the same completers. Shows using register-argument-completer reuse, how to return CompletionResult with icons and tooltips, and the newer class-based argument completers (PowerShell 7.2/7.3) plus notes on caching and error handling.
AI-written summary · about
chapters (15)
- 0:00Argument completers in PowerShell
- 1:14What are argument completers
- 3:24Static tab completion with ValidateSet
- 4:08Dynamic completers with script blocks
- 7:06Dynamic completers with icons
- 8:33Respect user input in completers
- 11:47Filter results by input
- 16:00Fake bound parameters for context
- 18:29REST API in completers
- 23:15Reuse completers across functions
- 26:54Register completers outside functions
- 29:37Octopus Deploy example
- 32:08Class-based argument completers
- 38:35Best practices for completers
- 39:41Q&A on caching and errors
related talks
35mImproving Your Attributes
01h 14mCreating a PowerShell Editor
43mPowerShell Tooling
01h 37mMore Game Breaking PowerShell
40mParameter Classes: Making parameter-binding user friendly
45mBullet-proofing Patterns & Practices
45mInteractive Enhancements to PowerShell
51mDon't do that, do this instead: PowerShell worst practices and..
