mirror of
https://github.com/pnpm/pnpm.git
synced 2026-07-14 09:42:37 -04:00
fix(ci): stage the Rust release binary outside the repo root before archiving (#12918)
The Release pnpm (Rust) workflow renamed the built binary to `pnpm` at the repo root before tarring it. Since the pacquet/ directory was renamed to pnpm/, that `mv` moved the binary *into* the existing `pnpm/` source directory instead, so the non-Windows archives contained the whole Rust source tree. The publish job then extracted a directory where it expected a binary and failed with EISDIR in generate-packages.mjs (https://github.com/pnpm/pnpm/actions/runs/29113833296). Stage the binary in a scratch directory and tar from there, keeping the archive layout (a plain `pnpm` binary at the root) unchanged. Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
9
.github/workflows/pacquet-release-to-npm.yml
vendored
9
.github/workflows/pacquet-release-to-npm.yml
vendored
@@ -166,9 +166,14 @@ jobs:
|
||||
|
||||
- name: Archive Binary
|
||||
if: runner.os != 'Windows'
|
||||
# The binary is staged in a scratch directory because the repo root
|
||||
# already has a `pnpm/` directory (the Rust sub-project) — renaming the
|
||||
# binary to `pnpm` in place would move it *into* that directory and tar
|
||||
# up the whole source tree instead.
|
||||
run: |
|
||||
mv target/${{ matrix.target }}/release/pacquet pnpm
|
||||
tar czf pnpm-${{ matrix.code-target }}.tar.gz pnpm
|
||||
mkdir stage
|
||||
mv target/${{ matrix.target }}/release/pacquet stage/pnpm
|
||||
tar czf pnpm-${{ matrix.code-target }}.tar.gz -C stage pnpm
|
||||
|
||||
- name: Attest build provenance
|
||||
uses: actions/attest-build-provenance@0f67c3f4856b2e3261c31976d6725780e5e4c373 # v4.1.1
|
||||
|
||||
Reference in New Issue
Block a user