Finding Alias Names in V2

Alias names are shortcuts for other commands, and you probably know that. In PowerShell V1, the only way to retrieve all aliases for a given target was this line:

Get-Alias | Where-Object { $_.Definition -eq 'Get-Childitem' }

In PowerShell V2, it is much simpler:

Get-Alias -definition Get-Childitem

Twitter This Tip! ReTweet this Tip!


Posted Aug 18 2009, 08:00 AM by ps1
Concentrated Tech NSoftware Dell Compellent Sponsored by Idera and Concentrated Tech and NSoftware and Dell Compellent
Copyright 2011 PowerShell.com. All rights reserved.