0
0
PowerShellscripting~5 mins

Command discovery (Get-Command) in PowerShell - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What does the PowerShell cmdlet <code>Get-Command</code> do?

Get-Command helps you find commands available in PowerShell. It shows cmdlets, functions, scripts, and applications you can run.

Click to reveal answer
beginner
How can you use Get-Command to find all commands that start with 'Get-'?

Use Get-Command Get-*. The asterisk * is a wildcard that matches any characters after 'Get-'.

Click to reveal answer
intermediate
What type of commands can Get-Command discover?

It finds cmdlets, functions, workflows, aliases, scripts, and applications available in your PowerShell session.

Click to reveal answer
beginner
How do you find the command that runs a specific executable, like 'notepad'?

Use Get-Command notepad. It shows the path and details of the executable.

Click to reveal answer
intermediate
What information does Get-Command provide about a command?

It shows the command's name, type (cmdlet, function, application), module it belongs to, and its path if applicable.

Click to reveal answer
Which cmdlet helps you find available commands in PowerShell?
AFind-Command
BGet-Command
CShow-Command
DSearch-Command
What does Get-Command Get-* do?
ADeletes commands starting with 'Get-'
BRuns all commands starting with 'Get-'
CFinds all commands starting with 'Get-'
DLists commands ending with '*'
Which command type is NOT found by Get-Command?
ACmdlets
BFunctions
CApplications
DDatabase tables
How do you find the path of the 'notepad' executable using PowerShell?
AGet-Command notepad
BFind-Path notepad
CShow-Path notepad
DGet-Path notepad
What info does Get-Command NOT provide about a command?
ACommand execution time
BCommand type
CModule name
DCommand name
Explain how you would use Get-Command to discover commands related to file management.
Think about searching commands with names containing 'File'.
You got /3 concepts.
    Describe the types of commands that Get-Command can find and why this is useful.
    Consider the variety of command types in PowerShell.
    You got /3 concepts.