Skip to content

ci: skip winget update during the first-submission window - #23

Merged
bsg62 merged 1 commit into
mainfrom
fix/winget-first-submission-guard
Jul 25, 2026
Merged

ci: skip winget update during the first-submission window#23
bsg62 merged 1 commit into
mainfrom
fix/winget-first-submission-guard

Conversation

@bsg62

@bsg62 bsg62 commented Jul 25, 2026

Copy link
Copy Markdown
Member

Adds a guard to the update-winget job so a release cut while the first WebCodr.jwtd submission is still under moderation is handled cleanly.

Why

komac update needs a merged base manifest as its template. WebCodr.jwtd is not yet in winget-pkgs main — the first submission (PR microsoft/winget-pkgs#407788, "New package … 5.2.0") is still in moderation. Cutting another release now would make komac either fail or open a second "New package" PR competing with the first.

What

A new first step queries whether the package exists in winget-pkgs main:

- name: Check whether WebCodr.jwtd is already in winget-pkgs
  id: pkg
  env:
    GH_TOKEN: ${{ github.token }}
  run: |
    if gh api repos/microsoft/winget-pkgs/contents/manifests/w/WebCodr/jwtd >/dev/null 2>&1; then
      echo "exists=true" >> "$GITHUB_OUTPUT"
    else
      echo "exists=false" >> "$GITHUB_OUTPUT"
      echo "::notice::… skipping the WinGet submission until the first-submission PR merges."
    fi

The download/verify/install-komac/submit steps are gated on steps.pkg.outputs.exists == 'true'. So during the first-submission window the job skips cleanly (emits a GHA notice) instead of failing or opening a duplicate PR; once the first PR merges and the package is in main, the guard passes and normal automation resumes with no further changes.

This changes nothing for the other channels — Homebrew/Scoop/AUR/COPR/release are independent jobs (needs: [validate, release]), unaffected either way.

Tests

TestWinGetInvariants now asserts the existence-check step exists and that the komac install/submit steps are gated on its output. Full suite + workflow security invariants pass. (The guard comment deliberately avoids the word the step-finder greps for, so the existing komac-step lookups stay unambiguous.)

🤖 Generated with Claude Code

The update-winget job runs komac update, which needs a merged base manifest
as its template and must not open a second "New package" PR while the first
WebCodr.jwtd submission is still under moderation. Add a guard step that
checks whether the package already exists in winget-pkgs main and gates the
komac install/submit steps on it, so a release cut during the
first-submission window skips WinGet cleanly (a GitHub Actions notice)
instead of failing the job or opening a duplicate new-package PR. Normal
automation resumes on its own once the first PR merges. Every other release
channel is an independent job, so this never affects them.

TestWinGetInvariants now asserts the existence check and that the komac
install/submit steps are gated on its output.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@bsg62
bsg62 merged commit 8591164 into main Jul 25, 2026
7 checks passed
@bsg62
bsg62 deleted the fix/winget-first-submission-guard branch July 25, 2026 19:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant