Results for “power”
Small, practical examples. Search by task or narrow things down below.
Format a bounded duration as hours minutes and seconds
PowerShell: TimeSpan can format duration components with escaped separators.
PowerShell✓ Tested
Handle a malformed JSON document
PowerShell: ConvertFrom-Json reports a terminating conversion error under the selected error preference.
PowerShell✓ Tested
Handle an expected terminating error
PowerShell: Handle an expected terminating error using PowerShell 7.
PowerShell✓ Tested
Insert a variable into a string
PowerShell: Insert a variable into a string using PowerShell 7.
PowerShell✓ Tested
Insert values into a multiline template
PowerShell: A double-quoted here-string expands variable references.
PowerShell✓ Tested
Inspect a URI through typed properties
PowerShell: The Uri class separates URL components without manual string splitting.
PowerShell✓ Tested
Join an array into text
PowerShell: Join an array into text using PowerShell 7.
PowerShell✓ Tested
Join several strings with a separator
PowerShell: The join operator returns one string from an input collection.
PowerShell✓ Tested
Keep a dollar sign literal
PowerShell: Keep a dollar sign literal using PowerShell 7.
PowerShell✓ Tested
Keep function-local assignments separate from caller state
PowerShell: Ordinary function assignments create local variables rather than replacing the caller’s variable.
PowerShell✓ Tested
Merge configuration maps with override precedence
PowerShell: Copy defaults before applying override keys so the original remains unchanged.
PowerShell✓ Tested
Move a file into another directory
PowerShell: Move-Item transfers an existing file to the chosen destination directory.
PowerShell✓ Tested