Winget windows package manager Page

winget Windows Package Manager



Return to PowerShell Module Installation - Install-Module WinGet, winget Windows Package Manager vs Chocolatey

winget - the Windows Package Manager

{{wp>Windows Package Manager}}

----

WinGet is a command-line tool for managing Windows software packages. It allows users to discover, install, upgrade, remove, and configure applications on Windows 10 and Windows 11 systems.

Here are some usage examples to help you get started with WinGet:

### Basic Commands

#### Search for a Package

To search for a package, use the `search` command:
```powershell
winget search
```
Example:
```powershell
winget search vscode
```

#### Install a Package

To install a package, use the `install` command:
```powershell
winget install
```
Example:
```powershell
winget install Microsoft.VisualStudioCode
```

#### Upgrade a Package

To upgrade a package, use the `upgrade` command:
```powershell
winget upgrade
```
Example:
```powershell
winget upgrade Microsoft.VisualStudioCode
```

#### List Upgradable Packages

To list all packages that have updates available, use the `upgrade` command without specifying a package name:
```powershell
winget upgrade
```

#### Uninstall a Package

To uninstall a package, use the `uninstall` command:
```powershell
winget uninstall
```
Example:
```powershell
winget uninstall Microsoft.VisualStudioCode
```

#### Show Package Details

To show details about a specific package, use the `show` command:
```powershell
winget show
```
Example:
```powershell
winget show Microsoft.VisualStudioCode
```

### Advanced Commands

#### Install a Package by ID

Each package in WinGet has a unique identifier. You can install a package using its ID:
```powershell
winget install --id
```
Example:
```powershell
winget install --id Microsoft.VisualStudioCode
```

#### Install a Specific Version

To install a specific version of a package, use the `--version` option:
```powershell
winget install --version
```
Example:
```powershell
winget install Microsoft.VisualStudioCode --version 1.56.2
```

#### Export and Import Package Lists

You can export a list of installed packages and then import it on another system.

**Export:**
```powershell
winget export -o packages.json
```

**Import:**
```powershell
winget import -i packages.json
```

#### Install Multiple Packages

You can install multiple packages by chaining the install commands:
```powershell
winget install Microsoft.VisualStudioCode && winget install Google.Chrome
```

### Examples of Commonly Used Packages

#### Install Google Chrome

```powershell
winget install Google.Chrome
```

#### Install 7-Zip

```powershell
winget install 7zip.7zip
```

#### Install Git

```powershell
winget install Git.Git
```

#### Install Node.js

```powershell
winget install OpenJS.NodeJS
```

### Scripting with WinGet

You can use WinGet in PowerShell scripts to automate software management tasks. Here’s an example script to install a list of applications:

```powershell
$packages = @(
"Google.Chrome",
"Microsoft.VisualStudioCode",
"7zip.7zip",
"Git.Git",
"OpenJS.NodeJS"
)

foreach ($package in $packages) {
winget install $package --silent --accept-package-agreements --accept-source-agreements
}
```

This script iterates through a list of package names and installs each one silently, accepting all package and source agreements.

WinGet is a powerful tool for managing software installations on Windows, simplifying the process of keeping applications up to date and ensuring consistency across multiple systems.

----


{{short description|Official open-source package manager for Windows 10/11}}
{{Infobox software
| name = Windows Package Manager
| title = Windows Package Manager
| logo =
| screenshot = Windows Package Manager v0.1.41331 Preview 1115x624.png
| caption =
| developer = Microsoft
| released = {{Start date and age|2020|05|13}}
| latest release version = v1.0.11692
| latest release date = {{Start date and age|2021|06|14}}{{cite web|url=https://github.com/microsoft/winget-cli/tags|title=Tags · microsoft/winget-cli · GitHub|website=GitHub|language=en|access-date=2021-07-10}}
| latest preview version = v-0.4.11391-preview
| latest preview date = {{Start date and age|2021|05|20}}{{r|github}}
| repo = {{URL|https://github.com/microsoft/winget-cli}}
| programming language = C++
| operating system = Windows 10, Windows 11
| platform =
| size =
| language = English
| language count =
| language footnote =
| genre = Package manager
| license = MIT License
| website = {{URL|https://docs.microsoft.com/en-us/windows/package-manager/}}
}}
The Windows Package Manager (also known as winget) is a free and open-source package manager designed by Microsoft for Windows 10 and Windows 11. It consists of a command-line utility and a set of services for installing applications.{{cite web|url=https://www.theverge.com/2020/5/20/21264739/microsoft-windows-package-manager-preview-download|title=Microsoft's new Windows Package Manager is already better than the Windows Store|author=Tom Warren|website=The Verge}}[https://devblogs.microsoft.com/commandline/windows-package-manager-preview/ Windows Package Manager Preview | Windows Command Line] Independent software vendor|ISVs can use it as a distribution channel for their software packages.

History


Windows Package Manager was first announced at the Microsoft Build (developer conference)|Build developer conference in May 2020.[https://venturebeat.com/2020/05/19/microsoft-windows-package-manager-powertoys/ Microsoft debuts Windows Package Manager for your dev environment | VentureBeat]

Before deciding to develop Windows Package Manager, the team behind it explored Chocolatey, Scoop, Ninite, AppGet, Npackd and the PowerShell-based OneGet. After the announcement of winget, Keivan Beigi, the developer of AppGet claimed{{Cite web|last=Beigi|first=Keivan|date=2020-05-25|orig-year=2020|title=The Day AppGet Died.|url=https://keivan.io/the-day-appget-died/|access-date=2020-06-25|website=Keivan Beigi|language=en}}{{Primary source inline|date=July 2021}} that Microsoft interviewed him in December 2019 under the pretense of acquiring AppGet and hiring Beigi. After talking with Beigi, Microsoft allegedly ceased communication with him until confirming one day before the launch of winget that they would not be hiring him. Beigi was dismayed at Microsoft's lack of attribution of AppGet. The release of winget led Beigi to announce that AppGet would be discontinued in August 2020.{{cite news|url=https://www.theverge.com/2020/5/28/21272964/microsoft-winget-windows-package-manager-appget-copied|title=Microsoft copied its new Windows Package Manager from rival AppGet, claims developer|first=Tom|last=Warren|date=28 May 2020|website=The Verge|publisher=Vox Media|access-date=June 1, 2020}}{{cite web|access-date=2020-06-01|title=Embrace and kill? AppGet dev claims Microsoft reeled him in with talk of help and a job – then released remarkably similar package manager|url=https://www.theregister.com/2020/05/28/appget_replaced_by_winget_says_dev/|first=Tim|last=Anderson|website=The Register|date=May 28, 2020}}{{cite web|first1=Ashley|last1=Stewart|access-date=June 1, 2020|title=A developer says Microsoft led him on about a job and buying his tool before going silent and releasing its own very similar service. Now he wants an explanation and credit for his work.|url=https://www.businessinsider.com/appget-developer-wants-credit-for-inspiring-microsoft-package-manager-2020-5|website=Business Insider|date=May 28, 2020}} Microsoft responded with a blog post crediting a number of winget's features to AppGet.{{cite web|first1=Liam|last1=Tung|access-date=2020-06-02|title=Windows 10: Microsoft now credits maker of package manager it 'copied' – but offers no apology|url=https://www.zdnet.com/article/microsoft-credits-maker-of-package-manager-it-copied-for-windows-10-but-offers-no-apology/|website=ZDNet|date=June 1, 2020}}[https://www.neowin.net/news/microsoft-gives-appget-creator-credit-for-windows-package-manager Microsoft gives AppGet creator credit for Windows Package Manager - Neowin]

Microsoft released version 1.0 of Windows Package Manager on May 27, 2021. The Microsoft Community Repository included over 1,400 packages at that date.{{cite web|first1=Tim|last1=Anderson|access-date=2021-05-28|title=Microsoft releases command-line package manager for Windows (there are snags)|url=https://www.theregister.com/2021/05/27/microsoft_releases_commandline_package_manager/|website=The Register|date=May 27, 2021}}

Overview


The winget tool supports installers based on .exe|EXE, .msix|MSIX, and .msi|MSI.[https://docs.microsoft.com/en-us/windows/package-manager/winget/ Use the winget tool to install and manage applications | Microsoft Docs] The public Windows Package Manager Community repository hosts manifest files for supported applications in YAML format.[https://github.com/microsoft/winget-pkgs GitHub - microsoft/winget-pkgs: The Microsoft community Windows Package Manager manifest repository] In September 2020, Microsoft added the ability to install applications from the Microsoft Store (digital)|Microsoft Store and a command auto-completion feature.{{cite web|first1=Lawrence|last1=Abrams|access-date=2020-10-10|title=Windows 10 Package Manager can now install Microsoft Store apps|url=https://www.bleepingcomputer.com/news/microsoft/windows-10-package-manager-can-now-install-microsoft-store-apps/|date=September 23, 2020|website=Bleeping Computer}}

To reduce the likelihood of malicious software making its way into the repository and onto the target machine, Windows Package Manager uses Microsoft SmartScreen, static analysis, SHA256 cryptographic hash function|hash validation and other processes.{{cite web|first1=Liam|last1=Tung|access-date=2020-06-02|title=Microsoft's Windows Package Manager: This command-line tool can install all your apps|url=https://www.zdnet.com/article/microsofts-windows-package-manager-this-command-line-tool-can-install-all-your-apps/|date=May 21, 2020|website=ZDNet}}[https://petri.com/how-to-use-windows-package-manager How to Use Windows Package Manager - Petri]

The winget client source code and the community manifest repository are licensed under MIT License and hosted on GitHub.{{Cite web|url=https://github.com/microsoft/winget-cli/ |title=GitHub - microsoft/winget-cli: Windows Package Manager CLI (a.k.a. winget)|date=May 20, 2020|via=GitHub}}

=Commands

=
{| class="wikitable" border="6"
! Name
! Description
|-
| export
| Exports a list of the installed applications
|-
| features
| Show status of experimental features
|-
| hash
| Hash installer files
|-
| import
| Install all the applications in a file
|-
| install
| Install the given application
|-
| list
| Display installed applications
|-
| show
| Show information about the given application
|-
| search
| Search and show basic information of applications
|-
| settings
| Open winget configuration settings
|-
| source
| Manage application sources
|-
| upgrade
| Upgrades the given application
|-
| uninstall
| Uninstall the given application
|-
| validate
| Validate a manifest file
|}

Example


The following example searches for and installs Visual Studio Code, a code editor from Microsoft.

winget install vscode


See also


{{Portal|Free and open-source software}}
* Web Platform Installer
* NuGet
* List of software package management systems

References


{{Reflist}}

External links


* [https://docs.microsoft.com/en-us/windows/package-manager/ Windows Package Manager | Microsoft Docs]
* {{GitHub|https://github.com/microsoft/winget-cli}}
* {{GitHub|https://github.com/microsoft/winget-pkgs}}


{{Package management systems navbar}}

{{Software digital distribution platforms navbar}}

{{Microsoft FOSS navbar}}



External Links


* https://docs.microsoft.com/en-us/windows/package-manager
* https://docs.microsoft.com/en-us/windows/package-manager/winget
** https://docs.microsoft.com/en-us/windows/package-manager/winget/install
** https://docs.microsoft.com/en-us/windows/package-manager/winget/list
** https://docs.microsoft.com/en-us/windows/package-manager/winget/settings
** https://docs.microsoft.com/en-us/windows/package-manager/winget/uninstall
** https://docs.microsoft.com/en-us/windows/package-manager/winget/upgrade
** https://docs.microsoft.com/en-us/windows/package-manager/winget/search
* https://docs.microsoft.com/en-us/windows/package-manager/package/windows-package-manager-policies
* https://github.com/microsoft/winget-pkgs - The Microsoft community Windows Package Manager manifest repository



ms>winget ms>Windows Package Manager