Finding and installing modules
PowerShell includes a module named PowerShellGet
, which can be used to register repositories and search for and install modules.
By default, PowerShellGet
searches the PowerShell Gallery.
What is the PowerShell Gallery?
The PowerShell Gallery is a Microsoft-run repository and distribution platform for PowerShell scripts and modules written by Microsoft or other users.
The PowerShell Gallery has parallels in other scripting languages, as shown in the following examples:
- Perl has cpan.org.
- Python has PyPI.
- Ruby has RubyGems.
Support for the gallery is included by default in PowerShell 5 and above. For Windows PowerShell 3 and 4, PowerShellGet
must be installed as described in Microsoft Learn:
https://learn.microsoft.com/en-us/powershell/gallery/powershellget/install-on-older-systems.
The PowerShell Gallery may be searched using https://www.powershellgallery.com, as shown in the following screenshot...