Skip to content

Feat: Add winget package distribution (fixes #137)#141

Merged
wkoszek merged 2 commits intomainfrom
issue/137
Nov 25, 2025
Merged

Feat: Add winget package distribution (fixes #137)#141
wkoszek merged 2 commits intomainfrom
issue/137

Conversation

@wkoszek
Copy link
Copy Markdown
Contributor

@wkoszek wkoszek commented Nov 25, 2025

Summary

Add GoReleaser configuration for publishing bsubio to Windows Package Manager (winget). GoReleaser will automatically create pull requests to the microsoft/winget-pkgs repository on each release.

Changes

  • Add winget section to .goreleaser.yaml
  • Configure package identifier as bsubio.bsubio
  • Set up automated PR creation to microsoft/winget-pkgs
  • Add winget installation instructions to release footer

Installation After Release

Windows users can install with:

winget install bsubio.bsubio

How It Works

  1. On release, GoReleaser generates winget package manifest
  2. Creates PR to https://github.com/microsoft/winget-pkgs
  3. Once PR is reviewed and merged by Microsoft, package becomes available
  4. Users can install via winget install bsubio.bsubio

Setup Required

To enable automated winget publishing:

  1. Create GitHub Personal Access Token with public_repo scope
  2. Add WINGET_GITHUB_TOKEN secret to GitHub repository settings
  3. On next release, GoReleaser will create PR to winget-pkgs

Package Details

  • Package identifier: bsubio.bsubio
  • Publisher: bsubio
  • License: MIT
  • Tags: cli, batch-jobs, job-scheduler, cloud, devops

Fixes #137

Add GoReleaser configuration for publishing bsubio to Windows Package
Manager (winget). GoReleaser will create pull requests to the
microsoft/winget-pkgs repository on each release.

Changes:
- Add winget section to .goreleaser.yaml
- Configure package identifier as bsubio.bsubio
- Set up automated PR creation to microsoft/winget-pkgs
- Add winget installation instructions to release footer

Windows users can install with:
  winget install bsubio.bsubio

Note: Requires WINGET_GITHUB_TOKEN secret (GitHub PAT with public_repo
scope) to be configured in GitHub Actions for automated PR creation.
@claude
Copy link
Copy Markdown

claude bot commented Nov 25, 2025

Review Feedback

Configuration Issues:

  1. Branch name mismatch (.goreleaser.yaml:214): microsoft/winget-pkgs uses master → should be main (Microsoft migrated in 2020).

  2. Missing description field: Winget manifests require description (not just short_description). Add full description similar to chocolateys section.

  3. Missing IDs field: Other sections (chocolateys, homebrew_casks) specify ids: [default] to target specific builds. Without this, behavior unclear for multi-build setups.

  4. Inconsistent homepage URLs: Line 207 uses https://bsub.io while other sections use https://www.bsub.io. Pick one for consistency.

  5. Token security: WINGET_GITHUB_TOKEN needs public_repo scope. Document this in PR description or add comment in config.

Best Practice:

Microsoft's winget-pkgs validation is strict. After merging, first release may fail if manifest doesn't match their schema. Consider:

  • Testing with goreleaser release --snapshot before actual release
  • Checking microsoft/winget-pkgs submission guidelines for current requirements

Critical Fix:

repository:
  branch: main  # not master

@claude
Copy link
Copy Markdown

claude bot commented Nov 25, 2025

Branch name issue: Line 214 uses branch: master but microsoft/winget-pkgs likely uses main. Verify and update to avoid PR creation failures.

Consider adding ids: [default] after name: bsubio (line 203) to explicitly link winget config to the archives build (matches chocolatey pattern at line 172).

@wkoszek wkoszek merged commit 0cdeb05 into main Nov 25, 2025
2 checks passed
@wkoszek wkoszek deleted the issue/137 branch November 25, 2025 06:12
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.

Verify winget package distribution is working

1 participant