Skip to content

Commit 7462562

Browse files
Boshenclaude
andauthored
ci(release): attach per-target vp binary archives to GitHub Releases (#1665)
## Summary - Package the existing `vite-global-cli-<target>` matrix artifacts into per-platform `.tar.gz` (unix) / `.zip` (windows) archives inside `reusable-release-build.yml`, and attach them to the GitHub Release alongside the existing `vp-setup-*.exe` installers. - Asset names use the Rust target triple verbatim (`vp-x86_64-unknown-linux-gnu.tar.gz`, `vp-x86_64-pc-windows-msvc.zip`, ...) so no name-mapping table is needed on the CI side. - Permissions are preserved because the archive is produced inside the same matrix job that builds the binary (no upload/download round-trip strip). ## Why The release pipeline already cross-compiles `vp` for 8 targets, but only the Windows `vp-setup.exe` installer ever reaches the GitHub Release. Tools like mise (`aqua:` backend) and aqua itself expect to consume binaries from GitHub Releases rather than npm tarballs — see [#943](#943). This is the minimal CI plumbing for that. Out of scope: aqua-registry PR, `jdx/mise` `registry/viteplus.toml` update, and resolving the runtime JS-sidecar dependency in `crates/vite_global_cli/src/js_executor.rs` — those are tracked separately on #943. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 6b0ae34 commit 7462562

2 files changed

Lines changed: 28 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,13 @@ jobs:
145145
echo "Installer binaries:"
146146
ls -la installer-release/ || echo "No installer binaries found"
147147
148+
- name: Download release archives
149+
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
150+
with:
151+
path: binary-release
152+
pattern: vp-release-archive-*
153+
merge-multiple: true
154+
148155
- name: 'Setup npm'
149156
run: npm install -g npm@latest
150157

@@ -203,6 +210,8 @@ jobs:
203210
target_commitish: ${{ github.sha }}
204211
files: |
205212
installer-release/vp-setup-*.exe
213+
binary-release/vp-*.tar.gz
214+
binary-release/vp-*.zip
206215
207216
- name: Publish GitHub Release
208217
env:

.github/workflows/reusable-release-build.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,25 @@ jobs:
102102
./target/${{ matrix.settings.target }}/release/vp-shim.exe
103103
if-no-files-found: error
104104

105+
- name: Package release archive
106+
shell: bash
107+
working-directory: ./target/${{ matrix.settings.target }}/release
108+
run: |
109+
if [ -f vp.exe ]; then
110+
7z a "vp-${{ matrix.settings.target }}.zip" vp.exe vp-shim.exe
111+
else
112+
tar -czf "vp-${{ matrix.settings.target }}.tar.gz" vp
113+
fi
114+
115+
- name: Upload release archive
116+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
117+
with:
118+
name: vp-release-archive-${{ matrix.settings.target }}
119+
path: |
120+
./target/${{ matrix.settings.target }}/release/vp-*.tar.gz
121+
./target/${{ matrix.settings.target }}/release/vp-*.zip
122+
if-no-files-found: error
123+
105124
- name: Upload installer binary artifact (Windows only)
106125
if: contains(matrix.settings.target, 'windows')
107126
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1

0 commit comments

Comments
 (0)