Skip to content

ci: reduce CLI build and snapshot time - #2739

Merged
fengmk2 merged 6 commits into
mainfrom
test/skip-slow-windows-snapshots
Sep 18, 2026
Merged

fengmk2 merged 6 commits into
mainfrom
test/skip-slow-windows-snapshots

Conversation

@fengmk2

@fengmk2 fengmk2 commented Sep 18, 2026 •

Copy link
Copy Markdown
Member

Linux and macOS snapshot shards and CLI E2E jobs rebuilt the same native binaries. A shared job now builds the native binding, global CLI, snapshot runner, and helper once per platform. The snapshot shards and CLI E2E jobs reuse these artifacts and build only TypeScript packages. These jobs no longer need Rust setup or a Cargo cache.

Jobs that reuse native binaries read Cargo metadata from the artifact and skip the preliminary CLI TypeScript build.

Eleven snapshot cases exceeded 20 seconds on Windows in CI run 35299447671. These cases now use skip-platforms = ["windows"]. Linux and macOS continue to run them.

All table values are seconds. Build times cover Build with upstream.

The snapshot build comparison uses native-cache misses in both run 35316025047 (b8d716e24) and run 35321861243 (304ba791d). After totals include the shared build and all three shards.

Platform Before: three shards After: shared build After: three shards After: total
Linux 1080 388 39 427
macOS 1166 377 36 413

Combined snapshot build time fell from 37m26s to 14m00s (62.6%).

CLI E2E build times compare run 35321861243 with measured PR run 35323220184 (3d4616e9e). These jobs now wait for the shared artifact instead of rebuilding when its cache is not ready.

Platform E2E build before E2E build after
Linux 16 13
macOS 367 14

Windows timings compare base run 35308723711 (78439cd9e) with the measured PR run. Snapshot times cover Run PTY snapshot tests.

Windows shard Build before Build after Snapshots before Snapshots after
1/3 77 25 172 121
2/3 73 28 119 125
3/3 66 28 157 152
Sum of shards 216 81 448 398

Totals add time across parallel jobs. They do not measure workflow duration. Runner and cache conditions can affect these single-run measurements.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Sep 18, 2026 •

Copy link
Copy Markdown

🚀 Deploying Preview to Cloudflare 🚀

Preview URL: https://test-skip-slow-windows-snapshots-viteplus-dev.voidzero-docs.workers.dev (commit 6bcb568)

This URL reflects your latest Preview deployment

Preview Deployments by commit

Status Deployment URL Commit Updated (UTC) See this deployment's details
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://675043c6-viteplus-dev.voidzero-docs.workers.dev 6bcb568 2026-09-18T11:27:41.927Z Visit the dashboard ↗
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://cef95a0a-viteplus-dev.voidzero-docs.workers.dev fc34de6 2026-09-18T08:42:19.565Z Visit the dashboard ↗
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://8aa72f96-viteplus-dev.voidzero-docs.workers.dev 3d4616e 2026-09-18T08:13:41.599Z Visit the dashboard ↗
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://4c8179b8-viteplus-dev.voidzero-docs.workers.dev 304ba79 2026-09-18T07:57:25.032Z Visit the dashboard ↗
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://888af46c-viteplus-dev.voidzero-docs.workers.dev b8d716e 2026-09-18T06:43:11.543Z Visit the dashboard ↗
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://148f3548-viteplus-dev.voidzero-docs.workers.dev 05133b1 2026-09-18T04:58:06.397Z Visit the dashboard ↗
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://5b4ec4c0-viteplus-dev.voidzero-docs.workers.dev f3912c9 2026-09-18T04:55:12.043Z Visit the dashboard ↗

@fengmk2
fengmk2 marked this pull request as ready for review September 18, 2026 04:55
@fengmk2
fengmk2 force-pushed the test/skip-slow-windows-snapshots branch from f3912c9 to 05133b1 Compare September 18, 2026 04:55
@fengmk2
fengmk2 requested a review from cpojer September 18, 2026 04:56
@fengmk2 fengmk2 changed the title test: skip slow CLI snapshot cases on Windows ci: reduce Windows CLI build and snapshot time Sep 18, 2026
@github-actions

github-actions Bot commented Sep 18, 2026 •

Copy link
Copy Markdown
Contributor

CLI artifact sizes (6bcb568)

Final release artifacts built by the canonical build-upstream and build-windows-cli actions.
The dist rows use the Linux build. The core total excludes .node files to match the release artifact.

Artifact Format Base PR Change
packages/cli/dist Directory total 2.15 MiB 2.15 MiB 0 B (0.00%)
packages/core/dist Directory total 3.95 MiB 3.95 MiB 0 B (0.00%)
Combined package dist Directory total 6.09 MiB 6.09 MiB 0 B (0.00%)
vp (Linux x64) Binary 11.22 MiB 11.22 MiB 0 B (0.00%)
vp (Linux x64) gzip -9 4.85 MiB 4.85 MiB 0 B (0.00%)
NAPI (Linux x64) Binary 32.03 MiB 32.03 MiB 0 B (0.00%)
NAPI (Linux x64) gzip -9 12.70 MiB 12.70 MiB 0 B (0.00%)
vp (macOS ARM64) Binary 8.36 MiB 8.36 MiB 0 B (0.00%)
vp (macOS ARM64) gzip -9 4.23 MiB 4.23 MiB 0 B (0.00%)
NAPI (macOS ARM64) Binary 39.64 MiB 39.64 MiB 0 B (0.00%)
NAPI (macOS ARM64) gzip -9 17.01 MiB 17.01 MiB 0 B (0.00%)
vp (Windows x64) Binary 9.10 MiB 9.10 MiB 0 B (0.00%)
vp (Windows x64) gzip -9 3.97 MiB 3.97 MiB 0 B (0.00%)
NAPI (Windows x64) Binary 26.99 MiB 26.99 MiB 0 B (0.00%)
NAPI (Windows x64) gzip -9 10.81 MiB 10.81 MiB -2 B (-0.00%)
Trampoline (Windows x64) Binary 13.50 KiB 13.50 KiB 0 B (0.00%)
Trampoline (Windows x64) gzip -9 7.03 KiB 7.03 KiB 0 B (0.00%)
Installer (Windows x64) Binary 4.53 MiB 4.53 MiB 0 B (0.00%)
Installer (Windows x64) gzip -9 2.12 MiB 2.12 MiB +1 B (+0.00%)

@fengmk2 fengmk2 changed the title ci: reduce Windows CLI build and snapshot time ci: reduce CLI build and snapshot time Sep 18, 2026
@fengmk2 fengmk2 self-assigned this Sep 18, 2026
@fengmk2 fengmk2 added test: e2e Auto run e2e tests test: install-e2e run vite install e2e test test: create-e2e Run `vp create` e2e tests test: sfw preview-build Publish this PR's commits to the registry bridge as preview builds labels Sep 18, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Registry bridge build (fc34de6)

This commit build is published to the registry bridge, which serves these as ordinary npm versions (every other package proxies to npmjs):

Package Version
vite-plus 0.0.0-commit.fc34de6d09defa0001912374f7845673c985aeb8
@voidzero-dev/vite-plus-core 0.0.0-commit.fc34de6d09defa0001912374f7845673c985aeb8

Install the Vite+ CLI built from this commit, then migrate a project:

# macOS / Linux
curl -fsSL https://raw.githubusercontent.com/voidzero-dev/vite-plus/fc34de6d09defa0001912374f7845673c985aeb8/packages/cli/install.sh | VP_PR_VERSION=2739 VP_LEGACY_INSTALLER_URL=https://raw.githubusercontent.com/voidzero-dev/vite-plus/fc34de6d09defa0001912374f7845673c985aeb8/packages/cli/install-legacy.sh bash
# Windows (PowerShell)
$env:VP_PR_VERSION="2739"; $env:VP_LEGACY_INSTALLER_URL="https://raw.githubusercontent.com/voidzero-dev/vite-plus/fc34de6d09defa0001912374f7845673c985aeb8/packages/cli/install-legacy.ps1"; irm https://raw.githubusercontent.com/voidzero-dev/vite-plus/fc34de6d09defa0001912374f7845673c985aeb8/packages/cli/install.ps1 | iex

Or download the standalone Windows installer built from this commit:

Architecture Installer
x64 vp-setup-x86_64-pc-windows-msvc.exe
Arm64 vp-setup-aarch64-pc-windows-msvc.exe

GitHub requires you to sign in and downloads each installer as a ZIP artifact. Extract vp-setup.exe, then run it against this preview build:

.\vp-setup.exe --version "0.0.0-commit.fc34de6d09defa0001912374f7845673c985aeb8" --registry "https://registry-bridge.viteplus.dev/"

After installing, upgrade the current project's vite-plus to this test build with:

vp migrate

Or point your package manager at the bridge registry https://registry-bridge.viteplus.dev/:

Package manager Registry config
npm / pnpm / Bun .npmrc: registry=https://registry-bridge.viteplus.dev/
Yarn (v2+) .yarnrc.yml: npmRegistryServer: "https://registry-bridge.viteplus.dev/"

Then pin the build (vite aliases to vite-plus-core; pnpm can use a catalog, npm an overrides entry):

{
  "devDependencies": {
    "vite-plus": "0.0.0-commit.fc34de6d09defa0001912374f7845673c985aeb8",
    "vite": "npm:@voidzero-dev/vite-plus-core@0.0.0-commit.fc34de6d09defa0001912374f7845673c985aeb8"
  }
}

@github-actions

Copy link
Copy Markdown
Contributor

🐳 Docker preview image

Built from this PR's registry bridge build:

Image Compressed size
ghcr.io/voidzero-dev/vite-plus:pr-2739 223MB
# remove any stale local copy from a previous run, then pull fresh
docker rmi ghcr.io/voidzero-dev/vite-plus:pr-2739 2>/dev/null; docker pull ghcr.io/voidzero-dev/vite-plus:pr-2739

Quick check:

docker run --rm ghcr.io/voidzero-dev/vite-plus:pr-2739 vp --version

See docs/guide/docker.md for usage.

@fengmk2
fengmk2 merged commit eddbf82 into main Sep 18, 2026
117 checks passed
@fengmk2
fengmk2 deleted the test/skip-slow-windows-snapshots branch September 18, 2026 11:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

preview-build Publish this PR's commits to the registry bridge as preview builds test: create-e2e Run `vp create` e2e tests test: e2e Auto run e2e tests test: install-e2e run vite install e2e test test: sfw

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants