Summary: Learn to unload all non-Microsoft Windows PowerShell modules.
Windows PowerShell is acting funny and I want to unload all modules that are not written by Microsoft.
How can I easily do this?
Use Get-Module to find all loaded modules, use the Where-Object cmdlet to filter for authors
that do not match Microsoft, and then pipe the results to the Remove-Module cmdlet:
Get-Module | where Author -notmatch 'microsoft' | Remove-Module
0 comments