LOGO

PackageManagement (OneGet) on Windows 10: A Guide

August 3, 2015
PackageManagement (OneGet) on Windows 10: A Guide

Package Management in Windows 10

Windows 10 incorporates a package management tool directly within PowerShell. Officially termed "PackageManagement" in its released form, it fundamentally relies on the open-source project known as OneGet.

Understanding PackageManagement (OneGet)

It’s important to note that PackageManagement, also referred to as OneGet, doesn’t function as a traditional package manager itself. Rather, it operates as a meta-package manager.

This means it provides a framework and a collection of PowerShell cmdlets designed to oversee various software types sourced from diverse locations.

The key benefit is a standardized approach to managing software, regardless of its origin or packaging format.

Essentially, PackageManagement offers a consistent interface for installing, updating, and removing software across different repositories.

This centralized control simplifies software management tasks for users and administrators alike.

Understanding PackageManagement / OneGet

Previously, we reported on OneGet, attempting to define its purpose and functionality. For those seeking further clarification, developer Garret Serack has published a detailed article, “10 things about OneGet that are different than you think.”

At its core, PackageManagement, built upon the open-source project OneGet, is now a component of PowerShell and, consequently, Windows 10. Its primary goal is to consolidate diverse package management approaches and software installation frameworks into a unified API.

This API is accompanied by a standardized collection of PowerShell cmdlets designed for software management. Initially, this tool isn’t intended for typical Windows 10 users or even advanced enthusiasts.

Microsoft does not maintain any official “OneGet repositories”; the concept of such repositories doesn’t currently exist. OneGet functions through providers, which grant access to software repositories, enabling management via standardized cmdlets.

The tool is primarily geared towards system administrators. Users comfortable with command-line interfaces previously had the option of utilizing a Chocolatey provider within OneGet to install desktop applications from the Chocolatey repository.

However, it’s important to note that OneGet isn’t limited to Chocolatey. While early iterations of OneGet included a Chocolatey provider as a demonstration, this feature has since been removed.

Furthermore, the functionality of this tool isn't exclusive to Windows 10. It can also be installed and utilized on older Windows versions as part of the Windows Management Framework (WMF) 5.0.

Additional Information

  • OneGet integrates various package management techniques.
  • It utilizes PowerShell cmdlets for streamlined software control.
  • The tool is designed with system administrators in mind.

The initial Chocolatey provider served as a proof of concept and is no longer available. Access to software is achieved through the use of specific providers.

Utilizing PackageManagement / OneGet

The PackageManagement system, comprised of cmdlets for PowerShell, requires the Windows PowerShell application to be launched for its operation. To view a listing of the available cmdlets, execute the following command:

Get-Command -Module PackageManagement

(It's important to note that the command Get-Command -Module OneGet will not function, as the module has been renamed to PackageManagement.)

how-to-use-packagemanagement-aka-oneget-on-windows-10-1.jpg

Currently, the released version of Windows 10 offers limited functionality within PackageManagement. Initial interest stemmed from its potential to integrate with Chocolatey, enabling streamlined installation of Windows programs from a unified location. However, Chocolatey remains usable on Windows 10 independently of PackageManagement / OneGet.

The cmdlets Get-PackageProvider and Get-PackageSource are used to display the package providers and sources that are currently available. A package source can be installed using the Register-PackageSource cmdlet. This process necessitates a URL for the desired source, requiring precise knowledge of the location you intend to add.

For instance, should a Chocolatey provider be developed by the community, it can be integrated into your system via this cmdlet. Conversely, the Unregister-PackageSource cmdlet facilitates the removal of a previously registered package source.

how-to-use-packagemanagement-aka-oneget-on-windows-10-2.jpg

To install software utilizing PackageManagement, it is essential to first register the source using the aforementioned Register-PackageSource cmdlet. Once registered, you can then search for, install, and uninstall packages using the following cmdlets.

The Find-Package cmdlet enables searching across your configured package sources. The Install-Package cmdlet then allows for the installation of the identified package, while the Uninstall-Package cmdlet removes a previously installed package:

Find-Package search

Install-Package name

Uninstall-Package name

The intention behind this system is to provide a simplified and standardized method for installing diverse software types from various sources, packaged in differing formats. With the launch of Windows 10 and PackageManagement, further integration with a wider range of software sources is anticipated, potentially streamlining server setup and automating software installation on new PCs.

For comprehensive information, refer to Microsoft’s official documentation pertaining to the PackageManagement cmdlets.

Contrary to initial expectations during its development phase, Microsoft is not actively adopting package management as a core feature for Windows 10. The company is not establishing its own software repositories, nor is Chocolatey being integrated into the final Windows 10 release. Even applications within the Windows Store are inaccessible through PackageManagement.

This functionality is primarily intended as a toolset for system administrators. Its future development and expansion remain to be observed.

#PackageManagement#OneGet#Windows 10#software installation#package manager#PowerShell