Cmdlets & the Help System
What is a Cmdlet?
A cmdlet (pronounced "command-let") is a built-in PowerShell command. They are the core building blocks of everything you do in PowerShell.
Cmdlets follow a consistent Verb-Noun naming pattern:
So Get-Process = get information about processes. Stop-Service = stop a service. Remove-Item = delete a file. The pattern is consistent throughout all of PowerShell!
Discovering Commands with Get-Command
Get-Command is your tool for finding available commands. Use wildcards (*) to search:
The Help System — Get-Help
Get-Help is your best friend. Whenever you encounter an unfamiliar cmdlet, use Get-Help to learn everything about it.
Update-Help once (as Administrator) to download the latest help files. Without this, help content may be missing or incomplete.Discovering Object Members with Get-Member
Since everything in PowerShell is an object, you can pipe any output to Get-Member to see what properties and methods it has:
Get-Command → find commands | Get-Help → understand a command | Get-Member → explore what an object can doParameters
Parameters customize how a cmdlet behaves. They start with a dash (-):
Aliases — Shortcuts for Cmdlets
PowerShell includes short aliases for common cmdlets. They're great in the console, but in scripts it's better to use full names for clarity:
-WhatIf: Preview Before You Act
Many cmdlets support -WhatIf. This shows you what would happen without actually doing it — perfect for testing dangerous operations before committing:
-WhatIf first. This can save you from accidentally deleting the wrong files.🧪 Try It Yourself
- Run
Get-Command -Verb Getand count how many cmdlets start with Get - Run
Get-Help Write-Host -Examplesand try one of the examples - Run
Get-Date | Get-Member— explore the DateTime object's properties - Run
Get-Aliasto see all aliases, orGet-Alias cdto check what cd does - Try
Remove-Item *.xyz -WhatIf(won't delete anything — it's a preview)
Key Takeaways
- Cmdlets follow the Verb-Noun pattern (Get-Process, Stop-Service, New-Item)
- Use
Get-Command *keyword*to discover commands - Use
Get-Help cmdlet -Examplesto learn how to use any command - Use
Get-Memberto explore what properties and methods an object has - Parameters start with
-(e.g.,-Recurse,-Filter) -WhatIfpreviews destructive operations safely