To give you some background, a package manager is essentially a utility that lets you automate the process of installing, updating, and removing softwares/packages on an operating system. The utility comprises of several softwares/packages and allows you to use the command-line utility (or terminal) to enter a bunch of commands that automatically pull up the package and download and install it on your system. While package manager is a common sight on Linux (and even macOS, for that matter), Windows users have been missing out on a native package manager all this time. As a result, it left users with no other option but to use a third-party utility like Chocolatey, to get a package manager up and working on Windows. However, that is about to change now, as Microsoft is finally bringing a native package manager in Windows 10. One of the reasons Microsoft could have gone with the idea of developing their own package manager probably appears to have to do with the ability to retain more control over the packages that users install on the system and the security implications that dependence on a third-party service might impose on the operating system. As with its native package manager, the company seems to be adamant at checking the manifest and hash validations for each package that come on board. At the time of writing this article, Microsoft is testing out the Windows Package Manager, which it suggests will roll-out to all Windows 10 users by Spring 2021 (roadmap). However, what’s interesting about the whole project is that you can get your hands on the package manager on your machine right now. Although, the set of commands and the software/services currently supported by the package manager are limited, so you cannot be completely dependent on it as of yet.
How to Get Windows Package Manager (aka Winget)
To get the Windows Package Manager (aka Winget) on your machine, you get two different options:
- Install an Insider Build for Windows 10 and sign up for the Windows Package Manager Insider Program. If you use this method, all the updates to the package manager will be taken care of automatically by the system, and you do not need to worry about anything. [Currently, the supported version required for the proper functioning of the client is Windows 10 1709 (build 16299)]
- Download Windows Package Manager bundle from GitHub. Since Microsoft has made the project open-source, you can head to GitHub and download and install the bundle on your machine. If you do not wish to use the Insider Build, this method is the best way to get the package manager running on your machine. However, do keep in mind that, since you are sideloading the package manager, any updates that roll out from the company will not reflect on your version unless you update it manually.
How to Install Windows Package Manager (Winget) using Github
- First, go to this link and download the app bundle on your machine.
- Next, open Microsoft Store on your computer and search for App Installer — make sure it is updated to the latest version.
- Go to the folder (you downloaded the app bundle in Step-1 to) and double-tap on it to install. Once done, you can check if Winget is installed on your system by opening Command Prompt or PowerShell and entering winget. Upon entering the command, you will see all the related, essential information about the package manager, along with the list of supported commands and how to use them.
How to use Windows Package Manager (aka Winget)
Windows Package Manager currently supports the following commands, which you can use to perform various operations:
install – installs the given application show – shows info about an application source – manage sources of applications search – find and show basic info of apps hash – helper to hash installer files validate – validates a manifest file –help – provides command-line help –info – provides additional data, helpful for troubleshooting –version – provides the version of the clients
To use these commands, first, open Command Prompt or PowerShell on your computer and enter the following commands to perform the desired functions:
winget search [app name] – to search (and get basic information) about an app winget show [app name] – to get detailed information about an app winget install [app name] – to install an app on your system
Similarly, following the above syntax, you can also perform other operations with winget or the Windows Package Manager. And in case you get stuck and want to know more about a specific command, you can type in winget, followed by the command, and append -? at the end. For instance, if you want to know more about the show command, you can type in winget show -?, and hit enter. Now, you will be presented with details on what the show command does, how to use it, and a list of arguments you can use with it to get/perform granular results/operations. Furthermore, if you look up for an app, but it is missing on the package manager’s repository, you can submit the package yourself. For this, you need to author and test a manifest and then submit a pull request on Github. You can learn more about submitting packages here.
How to install multiple apps using Windows Package Manager (Winget)
Once you have the Windows Package Manager installed on your machine, you can either install apps one-by-one using the install command listed in the previous section or can use a script to install a bunch of different apps at once. While the former approach works fine with the package manager, Tweeten developer Mehedi Hassan has come up with a solution that makes the latter possible. Called Winstall, the service is a web app that lets you bundle your favorite apps into a package and install all of them in one go. It uses Microsoft’s Windows package manager to let you bundle together all the Windows apps that you want on your machine, and based on your selection, creates an (installation) script. The website also has a premade collection of different bundles, created and shared by different users, which you can browse by clicking on the Packs button. For instance, it has bundles for web browsers, image editors, entertainment apps, and more, which you can use to get install apps on your system in one go.
To use Winstall, use the following steps:
Visit Winstall.
On the homepage, you can either tap on apps to add them to your bundle or scroll down to the bottom to view the premade featured packs. Alternatively, you can click on the Apps button to view a list of all the available apps.
i. Once you select multiple apps, click on the Generate script button to generate a script. When the script is generated, hit the Copy to clipboard button. [If you use PowerShell, flip the Show PowerShell script toggle, and then copy the script.] ii. On the other hand, if you chose a premade pack, select it, scroll to the bottom, and click on the Copy to clipboard button.
Open Command Prompt or Power Shell and paste the script.
Hit enter.
All your selected apps should now be installed on your computer. If you want to share your bundles with other Winstall users, head back to the website and log in using your Twitter account. Check the apps in your bundle and hit the Create Pack button.
Why should you use the Windows Package Manager?
While you can follow the traditional practice of installing an app/service on your system, wherein you visit the website of a software/service, download the installer, and install it manually, using a package manager simplifies the whole experience and saves a lot of time and hassle. In the same vein, when the need arises to update an app, a package manager allows you to simply use the command line utility and enter a few commands to update the software/service.