A. The cmdlet Get-Alias outputs a list of all the aliases available in the PowerShell session. Aliases are short names or alternate commands for longer PowerShell cmdlets. Aliases are also used to give alternate names to commands that may be more familiar in the command prompt. For example, there's an alias called "dir" for the Get-ChildItem cmdlet. A sample of the output is shown below.
PS C:\Users\john.SAVILLTECH> get-alias CommandType Name Definition ----------- ---- ---------- Alias % ForEach-Object Alias ? Where-Object Alias ac Add-Content Alias asnp Add-PSSnapIn Alias cat Get-Content Alias cd Set-Location Alias chdir Set-Location Alias clc Clear-Content Alias clear Clear-Host Alias clhy Clear-History Alias cli Clear-Item Alias clp Clear-ItemProperty Alias cls Clear-Host Alias clv Clear-Variable Alias compare Compare-Object Alias copy Copy-Item Alias cp Copy-Item Alias cpi Copy-Item Alias cpp Copy-ItemProperty Alias cvpa Convert-Path Alias dbp Disable-PSBreakpoint Alias del Remove-Item Alias diff Compare-Object Alias dir Get-ChildItemRelated Reading:
- PowerShell 101, Lesson 1
- 4 Ways to Help PowerShell Find External Tools
- PowerShell Pointers
- Essential Windows PowerShell Commands
Check out hundreds more useful Q&As like this in John Savill's FAQ for Windows. Also, watch instructional videos made by John at ITTV.net.
0 comments
Hide comments