2024-10-01 15:11:03 +02:00
|
|
|
|
<#
|
2023-01-09 13:55:16 +01:00
|
|
|
|
.SYNOPSIS
|
2024-02-26 15:53:08 +01:00
|
|
|
|
Lists verbs in PowerShell
|
2023-01-09 13:55:16 +01:00
|
|
|
|
.DESCRIPTION
|
2024-02-26 15:53:08 +01:00
|
|
|
|
This PowerShell script lists all allowed/recommended verbs in PowerShell.
|
2023-01-09 13:55:16 +01:00
|
|
|
|
.EXAMPLE
|
2024-02-26 15:53:08 +01:00
|
|
|
|
PS> ./list-powershell-verbs.ps1
|
2023-01-09 13:55:16 +01:00
|
|
|
|
|
|
|
|
|
Verb Group
|
|
|
|
|
---- -----
|
|
|
|
|
Add Common
|
|
|
|
|
...
|
|
|
|
|
.LINK
|
|
|
|
|
https://github.com/fleschutz/PowerShell
|
|
|
|
|
.NOTES
|
|
|
|
|
Author: Markus Fleschutz | License: CC0
|
|
|
|
|
#>
|
|
|
|
|
|
|
|
|
|
try {
|
|
|
|
|
Get-Verb | Sort-Object -Property Verb
|
|
|
|
|
exit 0 # success
|
|
|
|
|
} catch {
|
|
|
|
|
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
|
|
|
|
exit 1
|
2023-08-06 21:35:36 +02:00
|
|
|
|
}
|