20 C
Texas

What is the PowerShell Gallery?

Hello! It is well known that Node.js project developers have a package repository. In addition, these repositories have code snippets. For example, NPM. Likewise, .NET developers have NuGet. Consequently, developers of PowerShell scripts and modules have their own repository. We are talking about PowerShell Gallery. A service managed by Microsoft. There are useful modules with PowerShell commands. In addition to scripts that define a set of tasks and the sequencing of these tasks. In the following lines, we will define what the PowerShell Gallery is.

What are the most downloaded PowerShell Gallery packages?

This gallery currently has 66,367 packages. They have almost 3.2 billion downloads. Some of these packages have been developed by Microsoft itself. However, others have been created by the PowerShell user community. Below we will take a look at the most popular package types.

  • NetworkingDsc: DSC resources to configure aspects related to networks.
  • PSWindowsUpdate: This module contains cmdlets to manage the Windows Update client.
  • Az.Accounts: Module with cmdlets to manage user accounts in Azure Resource Manager.
  • PackageManagement: A package manager for accessing software over the Internet.
  • Computer ManagementDsc: DSC resources related to aspects of computer administration such as task scheduling, virtual memory management, power settings, etc.

Basic aspects of the mode of use

PowerShellGet is a very useful module. It allows any user to use the gallery to load, detect and download all kinds of packages. However, it is first necessary to install the latest version of NuGet. With this in mind, you have to use the following command:

Install-PackageProvider -Name NuGet -Force
- Advertisement -

If we do not do this and try to use it, then PowerShell itself will offer to install it. To search for modules related to Active Directory, then the system will display the following:

After installation, it is possible to start searching for the package:

Once the package is located, it can be installed. To do so, just run Install-Module. So the syntax would be as follows:

Install-Module -Name PowerShellGet

We have discussed the possibility of installing scripts. For this purpose, just add Install-Script followed by the name of the script. On the other hand, it is also possible to update the installed modules and scripts. With this in mind, we will use the Update-Module or Update-Script commands. Finally, it is also possible to check what is installed from the PowerShell Gallery. Just use the Get-InstalledModule and Get-InstalledScript commands. Ultimately we have seen what the PowerShell Gallery is. So you have at hand this package manager nurtured by Microsoft. Bye!

- Advertisement -
Everything Linux, A.I, IT News, DataOps, Open Source and more delivered right to you.
Subscribe
"The best Linux newsletter on the web"

LEAVE A REPLY

Please enter your comment!
Please enter your name here



Latest article