PowerTip: Find Aliases Exported by PowerShell Module

PowerTip: Find Aliases Exported by PowerShell Module

  • Comments 2
  • Likes

Summary: Find aliases that were exported from a Windows PowerShell module.

Hey, Scripting Guy! Question How can I find aliases that were exported from a particular module on my system?

Hey, Scripting Guy! Answer Use the Get-Command cmdlet, specify the module, pipe the results to the 
         Foreach-Object cmdlet, and then look for aliases:

Get-Command -Module CimCmdlets | foreach { Get-Alias -Definition $_.name -ea 0 }

Your comment has been posted.   Close
Thank you, your comment requires moderation so it may take a while to appear.   Close
Leave a Comment
  • The 0 input to "erroraction" (ea) resolves to "silentlycontinue", because it's the first enum value?