From 2d7e723cffc8628aec7ff8b3cb5823de3f4ea342 Mon Sep 17 00:00:00 2001 From: Zoltan Kochan Date: Fri, 10 Jul 2026 21:15:55 +0200 Subject: [PATCH] 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 --- .github/workflows/pacquet-release-to-npm.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pacquet-release-to-npm.yml b/.github/workflows/pacquet-release-to-npm.yml index cd9c6d196e..b21aba5b2b 100644 --- a/.github/workflows/pacquet-release-to-npm.yml +++ b/.github/workflows/pacquet-release-to-npm.yml @@ -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