All Projects → microsoft → winget-create

microsoft / winget-create

Licence: MIT license
The Windows Package Manager Manifest Creator command-line tool (aka wingetcreate)

Programming Languages

C#
18002 projects
powershell
5483 projects

Projects that are alternatives of or similar to winget-create

Winget Cli
Windows Package Manager CLI (aka winget)
Stars: ✭ 15,849 (+6851.32%)
Mutual labels:  package-manager, winget
agda-pkg
apkg - package manager for Agda
Stars: ✭ 30 (-86.84%)
Mutual labels:  package-manager
bramble
Purely functional build system and package manager
Stars: ✭ 173 (-24.12%)
Mutual labels:  package-manager
awesome-package-manager
☘ Awesome package manager resources
Stars: ✭ 87 (-61.84%)
Mutual labels:  package-manager
gitpack
Git-based package manager written in POSIX shell
Stars: ✭ 72 (-68.42%)
Mutual labels:  package-manager
sherpa
a mini-package-manager for QNAP NAS
Stars: ✭ 63 (-72.37%)
Mutual labels:  package-manager
loverocks
LÖVE + Luarocks
Stars: ✭ 80 (-64.91%)
Mutual labels:  package-manager
GuPM
🐶📦 Global Universal Project Manager -- Package manager, cli tool, scripts for all your projects and your system
Stars: ✭ 132 (-42.11%)
Mutual labels:  package-manager
get-bin-path
Get the current package's binary path
Stars: ✭ 25 (-89.04%)
Mutual labels:  package-manager
pint
A single-file command-line package manager for Windows.
Stars: ✭ 35 (-84.65%)
Mutual labels:  package-manager
MGM-Ability
No description or website provided.
Stars: ✭ 64 (-71.93%)
Mutual labels:  package-manager
cppan
Project evolved into Software Network: https://github.com/SoftwareNetwork/sw
Stars: ✭ 108 (-52.63%)
Mutual labels:  package-manager
glam
A cross-platform package manager.
Stars: ✭ 61 (-73.25%)
Mutual labels:  package-manager
diamond
Dependency management built for Sass, Less, and CSS.
Stars: ✭ 19 (-91.67%)
Mutual labels:  package-manager
wsjcpp
Yet another... C++ Source Package Manager
Stars: ✭ 18 (-92.11%)
Mutual labels:  package-manager
zpm
InterSystems ObjectScript Package Manager
Stars: ✭ 17 (-92.54%)
Mutual labels:  package-manager
honest
Are your installed packages _really_ the same as you saw on GitHub?
Stars: ✭ 25 (-89.04%)
Mutual labels:  package-manager
cati
Cati Unix Package Manager
Stars: ✭ 19 (-91.67%)
Mutual labels:  package-manager
piu
Cross platform package manager wrapper
Stars: ✭ 33 (-85.53%)
Mutual labels:  package-manager
importly
import map generator
Stars: ✭ 42 (-81.58%)
Mutual labels:  package-manager

Welcome to the Windows Package Manager Manifest Creator repository.

This repository contains the source code for the Windows Package Manager Manifest Creator. The Windows Package Manager Manifest Creator is designed to help generate or update manifest files for the Community repo.

Overview

Windows Package Manager Manifest Creator is an Open Source tool designed to help developers create, update, and submit manifest files to the Windows Package Manager repository.

Developers will use this tool to submit their applications for use with the Windows Package Manager.

Getting Started

For your convenience, WingetCreate can be acquired a number of ways.

Install from the github repo

The Windows Package Manager Manifest Creator is available for download from the winget-create repository. To install the package, simply click the the MSIX file in your browser. Once it has downloaded, click open.

Install with Windows Package Manager

winget install wingetcreate

Using Windows Package Manager Manifest Creator

WingetCreate has the following commands:

Command Description
New Command for creating a new manifest from scratch
Update Command for updating an existing manifest
Submit Command for submitting an existing PR
Token Command for managing cached GitHub personal access tokens
Settings Command for editing the settings file configurations
Cache Command for managing downloaded installers stored in cache
-? Displays command line help

Click on the individual commands to learn more.

Using Windows Package Manager Manifest Creator in a CI/CD pipeline

You can use WingetCreate to update your existing app manifest as part of your CI/CD pipeline. For reference, see the final task in this repo's release Azure pipeline.

Using the standalone exe:

The latest version of the standalone exe can be found at https://aka.ms/wingetcreate/latest, and the latest preview version can be found at https://aka.ms/wingetcreate/preview, both of these require .NET 5.0 to be installed on the build machine.

Make sure your build machine has the Microsoft Visual C++ Redistributable for Visual Studio already installed. Without this, the standalone WingetCreate exe will fail to execute and likely show a "DllNotFoundException" error.

Then simply add a new powershell task to download the exe, and run it to update your manifest. It's recommended to not hardcode your PAT in your script, but instead to use a secret pipeline variable.

- powershell: |
    iwr https://aka.ms/wingetcreate/latest -OutFile wingetcreate.exe
    .\wingetcreate.exe update <packageId> -u $(packageUrls) -v $(manifestVersion) -t $(GITHUB_PAT)
  displayName: Update package manifest in the OWC

Using the msixbundle:

Windows Server 2022 now supports App Execution Aliases, which means the alias wingetcreate can be used to run the tool after installing the msixbundle. The latest version of the msixbundle can be found at https://aka.ms/wingetcreate/latest/msixbundle. Similar to the standalone exe steps, download the msixbundle, add the package, and run wingetcreate to update your manifest.

Winget-Create has a dependency on the C++ Runtime Desktop framework package. Be sure to also download and install this package prior to installing wingetcreate as shown in the steps below.

- powershell: |
      # Download and install C++ Runtime framework package.
      iwr https://aka.ms/Microsoft.VCLibs.x64.14.00.Desktop.appx -OutFile $(vcLibsBundleFile)
      Add-AppxPackage $(vcLibsBundleFile)

      # Download Winget-Create msixbundle, install, and execute update.
      iwr https://aka.ms/wingetcreate/latest/msixbundle -OutFile $(appxBundleFile)
      Add-AppxPackage $(appxBundleFile)
      wingetcreate update Microsoft.WingetCreate -u $(packageUrl) -v $(manifestVersion) -t $(GITHUB_PAT) --submit

The CLI also supports creating or updating manifests with multiple installer URLs. You can either create new manifests with multiple installer nodes using the New Command or update existing manifests with multiple installer URLs using the Update Command.

GitHub Personal Access Token Permissions

When creating your own GitHub Personal Access Token (PAT) to be used with WingetCreate, make sure the following permissions are selected.

  • Select the public_repo scope to allow access to public repositories

public_repo scope

  • (Optional) Select the delete_repo scope permission if you want WingetCreate to automatically delete the forked repo that it created if the PR submission fails.

Building the client

Prerequisites

  • Windows 10 1709 (16299) or later
  • Visual Studio 2019
    • Or use winget to install it ;) (although you may need to adjust the workloads via Tools->Get Tools and Features...)
  • Git Large File Storage (LFS)
  • The following workloads:
    • .NET Desktop Development
    • Universal Windows Platform Development

Building

Open winget-create\src\WingetCreateCLI.sln in Visual Studio and build. We currently only build using the solution; command line methods of building a VS solution should work as well.

Testing the client

Running Unit and E2E Tests

Running unit and E2E tests are a great way to ensure that functionality is preserved across major changes. You can run these tests in Visual Studio Test Explorer.

Testing Prerequisites

  • Fork the winget-pkgs-submission-test repository

  • Fill out the test parameters in the WingetCreateTests/Test.runsettings file

    • WingetPkgsTestRepoOwner: The repository owner of the winget-pkgs-submission-test repo. (Repo owner must be forked from main "winget-pkgs-submission-test" repo)
    • WingetPkgsTestRepo: The winget-pkgs test repository. (winget-pkgs-submission-test)
    • GitHubApiKey: GitHub personal access token for testing.
    • GitHubAppPrivateKey: Leave blank, this is only used by the build server.
  • Set the solution wide runsettings file for the tests

    • Go to Test menu > Configure Run Settings -> Select Solution Wide runsettings File -> Choose your configured runsettings file

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com. More information is available in our CONTRIBUTING.md file.

When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information, please refer to the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

Data/Telemetry

The wingetcreate.exe client is instrumented to collect usage and diagnostic (error) data and sends it to Microsoft to help improve the product.

If you build the client yourself the instrumentation will not be enabled and no data will be sent to Microsoft.

The wingetcreate.exe client respects machine wide privacy settings and users can opt-out on their device, as documented in the Microsoft Windows privacy statement here.

In short to opt-out, go to Start, then select Settings > Privacy > Diagnostics & feedback, and select Basic.

You can also opt-out of telemetry by configuring the settings.json file and setting the telemetry.disabled field to true. More information can be found in our Settings Command documentation

See the privacy statement for more details.

Known Issues

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].