🖥️

Guide to Using Winget on Windows

Aug 8, 2024

Overview of Winget Package Manager in Windows

Introduction to Winget

  • Winget is the built-in package manager for Windows.
  • Accessed via PowerShell or Terminal (Run as Admin).

Basic Commands

  1. Launching Winget

    • Open PowerShell or Terminal.
    • Run winget to view available commands.
  2. Searching for Applications

    • Command: winget search <application name>
    • Example: winget search Google Chrome
    • Displays results for the application along with versions (e.g., standard, beta, dev, canary).
  3. Getting Application Details

    • Command: winget show <application name>
    • Provides the manifest file with version, publisher, description, installer URL, and hash.
  4. Installing Applications

    • Command: winget install <application name>
    • Example: winget install Google Chrome
    • Automatically downloads and installs the application.

Managing Installed Applications

  1. Listing Installed Applications

    • Command: winget list
    • Displays all applications installed via Winget.
  2. Checking for Upgrades

    • Command: winget upgrade
    • Lists applications with updates available.
    • To upgrade a specific application: winget upgrade <application ID>.
    • To upgrade all applications: winget upgrade --all.

Exporting and Importing Application Lists

  1. Exporting Installed Applications

    • Command: winget export -o <file path>.json
    • Saves a list of all installed packages in JSON format.
  2. Uninstalling Applications

    • Command: winget uninstall <application name>
    • Example: winget uninstall Google Chrome
    • Verifying uninstallation via winget list.
  3. Importing Applications from JSON

    • Command: winget import -i <file path>.json
    • Automates the installation of previously exported applications.

Use Cases

  • Useful for setting up new computers or creating a template of installed applications.
  • Streamlines the process of maintaining application versions.