Detecting Conflicts between Aliases, Functions, and Cmdlets

PowerShell Team

Version 1.1 of the PowerShell Community Extensions has just been release so I decided to kick the tires. After I installed it, I noticed that some conflicts and then realized that there might be conflicts between my customizations and the Aliases, Functions and Cmdlets that they delivered. Here is how I detected what needed to be resolved:

PS> gcm -type cmdlet,function,alias |group name |where {$_.count -gt 1}

Count Name Group
—– —- —–
2 Get-FileVersionInfo {Get-FileVersionInfo, Get-FileVersionInfo}
2 help {help, help}
2 man {man, man}
2 mkdir {mkdir, mkdir}
2 ql {ql, ql}
2 qs {qs, qs}
PS> gcm qs

CommandType Name Definition
———– —- ———-
Function qs “$args”
Alias qs Quote-String


Is that cool or what? Man I love PowerShell!

Enjoy.

Jeffrey Snover [MSFT]
Windows PowerShell/MMC Architect
Visit the Windows PowerShell Team blog at: http://blogs.msdn.com/PowerShell
Visit the Windows PowerShell ScriptCenter at: http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx

0 comments

Discussion is closed.

Feedback usabilla icon