From 3b3b55cc2718deb0fea2ca07663a57ecd239d481 Mon Sep 17 00:00:00 2001 From: Ruben Arts Date: Wed, 6 Dec 2023 16:24:05 +0100 Subject: [PATCH] feat: add winget releaser --- .github/workflows/release.yml | 13 +++++++++++++ README.md | 5 +++++ docs/index.md | 7 +++++-- 3 files changed, 23 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 000000000..b29148b90 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,13 @@ +name: Publish to WinGet +on: + release: + types: [released] +jobs: + publish: + runs-on: windows-latest + steps: + - uses: vedantmgoyal2009/winget-releaser@v2 + with: + identifier: Package.Identifier + installers-regex: '\.msi' # Only .msi files + token: ${{ secrets.WINGET_TOKEN }} diff --git a/README.md b/README.md index 60e350049..3a5960ac9 100644 --- a/README.md +++ b/README.md @@ -92,6 +92,11 @@ To install Pixi on Windows, open a PowerShell terminal (you may need to run it a iwr -useb https://pixi.sh/install.ps1 | iex ``` The script will inform you once the installation is successful and add the ~/.pixi/bin directory to your PATH, which will allow you to run the pixi command from any location. +Or with `winget` +``` +winget install prefix-dev.pixi +``` + ### Autocompletion diff --git a/docs/index.md b/docs/index.md index c31f9aeb7..8110a6d4b 100644 --- a/docs/index.md +++ b/docs/index.md @@ -23,11 +23,14 @@ To install `pixi` you can run the following command in your terminal: The script will also update your `~/.bash_profile` to include `~/.pixi/bin` in your PATH, allowing you to invoke the `pixi` command from anywhere. === "Windows" - PowerShell: + `PowerShell`: ```powershell iwr -useb https://pixi.sh/install.ps1 | iex ``` - + `winget`: + ``` + winget install prefix-dev.pixi + ``` The above invocation will automatically download the latest version of `pixi`, extract it, and move the `pixi` binary to `LocalAppData/pixi/bin`. If this directory does not already exist, the script will create it.