Skip to content

fix: stop leaking staged npm package files into GitHub Releases#535

Merged
kexi merged 1 commit into
developfrom
fix/release-asset-noise
Jun 25, 2026
Merged

fix: stop leaking staged npm package files into GitHub Releases#535
kexi merged 1 commit into
developfrom
fix/release-asset-noise

Conversation

@kexi

@kexi kexi commented Jun 23, 2026

Copy link
Copy Markdown
Owner

Summary

GitHub Releases (v2.0.0, v2.1.0, …) carry two stray assets — package.json and THIRD-PARTY-LICENSES.md — alongside the actual binaries and .deb packages.

Root cause

The release job downloads every prior-job artifact with merge-multiple: true. The five platform-package-* artifacts produced by stage-platform-packages each contain a package.json + bin/vibe-* + THIRD-PARTY-LICENSES.md; merge-multiple flattens them into a single artifacts/ directory, so artifacts/package.json and artifacts/THIRD-PARTY-LICENSES.md get last-write-wins-overwritten by the five matrix variants and then uploaded by softprops/action-gh-release via files: artifacts/*.

Why this is safe to drop

publish-npm.yml does not consume those Release assets:

  • It regenerates package.json and THIRD-PARTY-LICENSES.md per-matrix-entry from the checked-out source via scripts/stage-platform-package.ts + scripts/generate-third-party-licenses.ts.
  • It only pulls the named binary from the Release via gh release download --pattern \"\$ARTIFACT\".

Homebrew, the .deb packages, and direct binary downloads also don't reference those assets.

Change

Replace files: artifacts/* with an explicit list:

files: |
  artifacts/vibe-*-*
  artifacts/vibe_*.deb

(.deb files are named vibe_<version>_<arch>.deb — underscore separators — so the second glob is intentionally different from the first.)

Test plan

  • CI green
  • On the next release, gh release view <tag> --json assets --jq '.assets[].name' should list only the five binaries + the two .deb files (no package.json, no THIRD-PARTY-LICENSES.md)

The `release` job downloads every prior-job artifact with
`merge-multiple: true`, which flattens the five `platform-package-*`
artifacts produced by `stage-platform-packages` into `artifacts/`.
Because each of those artifacts contains a `package.json` and a
`THIRD-PARTY-LICENSES.md`, those files land alongside the binaries
and get uploaded to the GitHub Release as `package.json` and
`THIRD-PARTY-LICENSES.md` (one each, last-write-wins).

publish-npm.yml does not consume those Release assets — it
regenerates `package.json` / `THIRD-PARTY-LICENSES.md` locally per
matrix entry, and only pulls the named binary via
`gh release download --pattern $ARTIFACT`. So scoping the upload to
just the binaries and `.deb` packages is safe.
@kexi kexi self-assigned this Jun 23, 2026
@kexi kexi merged commit f620b72 into develop Jun 25, 2026
26 checks passed
@kexi kexi deleted the fix/release-asset-noise branch June 25, 2026 13:44
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