From b1fb8a58c0b3a86d7ede3e9f8b313d557ec1c6de Mon Sep 17 00:00:00 2001 From: Felipe Pires Morandini Date: Wed, 18 Mar 2026 17:26:24 -0300 Subject: [PATCH 1/2] ci: add Winget automation to release workflow Add update-winget job to release.yml that uses wingetcreate to automatically submit manifest updates to microsoft/winget-pkgs on each release. Update Winget manifests with real SHA256 hashes for v0.6.1 release assets. Update ROADMAP to mark all distribution channels complete. --- .github/workflows/release.yml | 22 +++++++++++++++++++ ROADMAP.md | 15 +++++-------- .../FelipeMorandini.smartlog.installer.yaml | 10 ++++----- ...FelipeMorandini.smartlog.locale.en-US.yaml | 2 +- .../winget/FelipeMorandini.smartlog.yaml | 2 +- 5 files changed, 35 insertions(+), 16 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a30e0c4..63898ef 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -309,6 +309,28 @@ jobs: git commit -m "Update to v${VERSION}" git push + update-winget: + name: Update Winget manifest + needs: release + runs-on: windows-latest + steps: + - name: Install wingetcreate + shell: pwsh + run: | + Invoke-WebRequest -Uri "https://aka.ms/wingetcreate/latest" -OutFile wingetcreate.exe + + - name: Update and submit manifest + shell: pwsh + run: | + $version = "${{ github.ref_name }}".TrimStart("v") + $x64Url = "https://github.com/felipemorandini/smartlog/releases/download/${{ github.ref_name }}/smartlog-x86_64-pc-windows-msvc.zip" + $arm64Url = "https://github.com/felipemorandini/smartlog/releases/download/${{ github.ref_name }}/smartlog-aarch64-pc-windows-msvc.zip" + .\wingetcreate.exe update FelipeMorandini.smartlog ` + --version $version ` + --urls $x64Url $arm64Url ` + --submit ` + --token ${{ secrets.WINGET_PAT }} + update-homebrew: name: Update Homebrew formula needs: release diff --git a/ROADMAP.md b/ROADMAP.md index 7426b98..0d40706 100644 --- a/ROADMAP.md +++ b/ROADMAP.md @@ -14,12 +14,12 @@ - [x] Register `smartlog-bin` on the AUR and push initial PKGBUILD - [x] Automate AUR updates in the release workflow (`update-aur` job in `release.yml`) -### 6.3 Winget Manifest (Windows) — PARTIALLY DONE +### 6.3 Winget Manifest (Windows) — DONE - [x] Create a manifest (v1.6.0 schema) pointing to the GitHub Release `.zip` assets - [x] Add `winget install` instructions to README -- [ ] Compute real SHA256 hashes for current release assets -- [ ] Submit initial PR to [microsoft/winget-pkgs](https://github.com/microsoft/winget-pkgs) -- [ ] Automate manifest updates via [wingetcreate](https://github.com/microsoft/winget-create) in the release workflow +- [x] Compute real SHA256 hashes for current release assets +- [x] Submit initial PR to [microsoft/winget-pkgs](https://github.com/microsoft/winget-pkgs) +- [x] Automate manifest updates via `wingetcreate` in the release workflow (`update-winget` job) ### 6.4 CHANGELOG.md — DONE - [x] Create a `CHANGELOG.md` following [Keep a Changelog](https://keepachangelog.com) format @@ -34,10 +34,7 @@ ## Remaining Work -| Priority | Item | Effort | Description | -|----------|------|--------|-------------| -| Medium | Winget submission | Small | Compute checksums, submit initial PR to winget-pkgs | -| Medium | Winget automation | Medium | Add `wingetcreate` step to release workflow for auto-submission | +All distribution channels are complete. No remaining work. ## Completed Distribution Channels @@ -48,4 +45,4 @@ | crates.io | Yes | Published on release | | Debian .deb (x86_64 + ARM64) | Yes | Built and attached to release | | AUR (Arch Linux) | Yes | `update-aur` job in release.yml, `AUR_SSH_KEY` secret configured | -| Winget (Windows) | No | Template in `packaging/winget/`, manual submission | +| Winget (Windows) | Yes | `update-winget` job in release.yml, `WINGET_PAT` secret configured | diff --git a/packaging/winget/FelipeMorandini.smartlog.installer.yaml b/packaging/winget/FelipeMorandini.smartlog.installer.yaml index 80e698a..119343a 100644 --- a/packaging/winget/FelipeMorandini.smartlog.installer.yaml +++ b/packaging/winget/FelipeMorandini.smartlog.installer.yaml @@ -1,7 +1,7 @@ # yaml-language-server: $schema=https://aka.ms/winget-manifest.installer.1.6.0.schema.json PackageIdentifier: FelipeMorandini.smartlog -PackageVersion: 0.5.0 +PackageVersion: 0.6.1 InstallerType: zip NestedInstallerType: portable NestedInstallerFiles: @@ -9,10 +9,10 @@ NestedInstallerFiles: PortableCommandAlias: smartlog Installers: - Architecture: x64 - InstallerUrl: https://github.com/felipemorandini/smartlog/releases/download/v0.5.0/smartlog-x86_64-pc-windows-msvc.zip - InstallerSha256: PLACEHOLDER_UPDATE_ON_RELEASE + InstallerUrl: https://github.com/felipemorandini/smartlog/releases/download/v0.6.1/smartlog-x86_64-pc-windows-msvc.zip + InstallerSha256: 592990BEF6FDFEA5A2BA87DAA468D28F03B2D7C23AB85DB60DA615867DB946AD - Architecture: arm64 - InstallerUrl: https://github.com/felipemorandini/smartlog/releases/download/v0.5.0/smartlog-aarch64-pc-windows-msvc.zip - InstallerSha256: PLACEHOLDER_UPDATE_ON_RELEASE + InstallerUrl: https://github.com/felipemorandini/smartlog/releases/download/v0.6.1/smartlog-aarch64-pc-windows-msvc.zip + InstallerSha256: 6F5B261B2A28787B63D8DB2CF2006474E584DA071899AB8969FBD0C7F147401E ManifestType: installer ManifestVersion: 1.6.0 diff --git a/packaging/winget/FelipeMorandini.smartlog.locale.en-US.yaml b/packaging/winget/FelipeMorandini.smartlog.locale.en-US.yaml index 61f906f..31e9ea8 100644 --- a/packaging/winget/FelipeMorandini.smartlog.locale.en-US.yaml +++ b/packaging/winget/FelipeMorandini.smartlog.locale.en-US.yaml @@ -1,7 +1,7 @@ # yaml-language-server: $schema=https://aka.ms/winget-manifest.defaultLocale.1.6.0.schema.json PackageIdentifier: FelipeMorandini.smartlog -PackageVersion: 0.5.0 +PackageVersion: 0.6.1 PackageLocale: en-US Publisher: Felipe Pires Morandini PublisherUrl: https://github.com/felipemorandini diff --git a/packaging/winget/FelipeMorandini.smartlog.yaml b/packaging/winget/FelipeMorandini.smartlog.yaml index 646fe5a..13f0601 100644 --- a/packaging/winget/FelipeMorandini.smartlog.yaml +++ b/packaging/winget/FelipeMorandini.smartlog.yaml @@ -1,7 +1,7 @@ # yaml-language-server: $schema=https://aka.ms/winget-manifest.version.1.6.0.schema.json PackageIdentifier: FelipeMorandini.smartlog -PackageVersion: 0.5.0 +PackageVersion: 0.6.1 DefaultLocale: en-US ManifestType: version ManifestVersion: 1.6.0 From c97766ced3bbf50ff6e236cca95c4d6746354a25 Mon Sep 17 00:00:00 2001 From: Felipe Pires Morandini Date: Wed, 18 Mar 2026 17:31:26 -0300 Subject: [PATCH 2/2] ci: address Copilot review - use env var for PAT, add error handling --- .github/workflows/release.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 63898ef..7b4a79a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -317,11 +317,16 @@ jobs: - name: Install wingetcreate shell: pwsh run: | - Invoke-WebRequest -Uri "https://aka.ms/wingetcreate/latest" -OutFile wingetcreate.exe + $ErrorActionPreference = 'Stop' + Invoke-WebRequest -Uri "https://aka.ms/wingetcreate/latest/self-contained" -OutFile wingetcreate.exe + if (-not (Test-Path wingetcreate.exe)) { throw "Failed to download wingetcreate" } - name: Update and submit manifest shell: pwsh + env: + WINGET_PAT: ${{ secrets.WINGET_PAT }} run: | + $ErrorActionPreference = 'Stop' $version = "${{ github.ref_name }}".TrimStart("v") $x64Url = "https://github.com/felipemorandini/smartlog/releases/download/${{ github.ref_name }}/smartlog-x86_64-pc-windows-msvc.zip" $arm64Url = "https://github.com/felipemorandini/smartlog/releases/download/${{ github.ref_name }}/smartlog-aarch64-pc-windows-msvc.zip" @@ -329,7 +334,7 @@ jobs: --version $version ` --urls $x64Url $arm64Url ` --submit ` - --token ${{ secrets.WINGET_PAT }} + --token $env:WINGET_PAT update-homebrew: name: Update Homebrew formula