fix(cli): improve workspace app target classification - #2530
Conversation
✅ Deploy Preview for viteplus-preview canceled.
|
Native binary sizes (
|
| Artifact | Format | Base | PR | Change |
|---|---|---|---|---|
vp (Linux x64) |
Binary | 10.73 MiB | 10.74 MiB | +4.00 KiB (+0.04%) |
vp (Linux x64) |
gzip -9 | 4.64 MiB | 4.65 MiB | +867 B (+0.02%) |
| NAPI (Linux x64) | Binary | 32.20 MiB | 32.21 MiB | +4.00 KiB (+0.01%) |
| NAPI (Linux x64) | gzip -9 | 12.69 MiB | 12.69 MiB | +1.75 KiB (+0.01%) |
vp (macOS ARM64) |
Binary | 8.03 MiB | 8.03 MiB | 0 B (0.00%) |
vp (macOS ARM64) |
gzip -9 | 4.05 MiB | 4.05 MiB | +2.53 KiB (+0.06%) |
| NAPI (macOS ARM64) | Binary | 39.80 MiB | 39.80 MiB | +16 B (+0.00%) |
| NAPI (macOS ARM64) | gzip -9 | 16.98 MiB | 16.99 MiB | +5.96 KiB (+0.03%) |
vp (Windows x64) |
Binary | 8.63 MiB | 8.63 MiB | +3.00 KiB (+0.03%) |
vp (Windows x64) |
gzip -9 | 3.77 MiB | 3.77 MiB | +1.12 KiB (+0.03%) |
| NAPI (Windows x64) | Binary | 27.03 MiB | 27.04 MiB | +3.50 KiB (+0.01%) |
| NAPI (Windows x64) | gzip -9 | 10.75 MiB | 10.76 MiB | +2.58 KiB (+0.02%) |
| Trampoline (Windows x64) | Binary | 214.00 KiB | 214.00 KiB | 0 B (0.00%) |
| Trampoline (Windows x64) | gzip -9 | 103.20 KiB | 103.20 KiB | 0 B (0.00%) |
| Installer (Windows x64) | Binary | 4.50 MiB | 4.50 MiB | 0 B (0.00%) |
| Installer (Windows x64) | gzip -9 | 2.11 MiB | 2.11 MiB | 0 B (0.00%) |
Registry bridge build (
|
| Package | Version |
|---|---|
vite-plus |
0.0.0-commit.b011f8f2492b551faa08b86bca3aa224cd581cf6 |
@voidzero-dev/vite-plus-core |
0.0.0-commit.b011f8f2492b551faa08b86bca3aa224cd581cf6 |
Install the Vite+ CLI built from this commit, then migrate a project:
# macOS / Linux
curl -fsSL https://raw.githubusercontent.com/voidzero-dev/vite-plus/b011f8f2492b551faa08b86bca3aa224cd581cf6/packages/cli/install.sh | VP_PR_VERSION=2530 bash# Windows (PowerShell)
$env:VP_PR_VERSION="2530"; irm https://raw.githubusercontent.com/voidzero-dev/vite-plus/b011f8f2492b551faa08b86bca3aa224cd581cf6/packages/cli/install.ps1 | iexOr 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.b011f8f2492b551faa08b86bca3aa224cd581cf6" --registry "https://registry-bridge.viteplus.dev/"After installing, upgrade the current project's vite-plus to this test build with:
vp migrateOr 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.b011f8f2492b551faa08b86bca3aa224cd581cf6",
"vite": "npm:@voidzero-dev/vite-plus-core@0.0.0-commit.b011f8f2492b551faa08b86bca3aa224cd581cf6"
}
}
🐳 Docker preview imageBuilt from this PR's registry bridge build:
# remove any stale local copy from a previous run, then pull fresh
docker rmi ghcr.io/voidzero-dev/vite-plus:pr-2530 2>/dev/null; docker pull ghcr.io/voidzero-dev/vite-plus:pr-2530Quick check: docker run --rm ghcr.io/voidzero-dev/vite-plus:pr-2530 vp --versionSee docs/guide/docker.md for usage. |
Vite+ now uses one signal set when it selects a workspace-root app for
vp dev,vp build, andvp preview. Any declaredroot,build,input,environments, orappTypefield selects the root. A sourceindex.htmlalso selects it. Vite+ does not inspect declared values.dist/index.htmlis not a signal.When no root signal exists, the picker and non-interactive list show the workspace root as
.. This row comes after all member rows. It does not affect automatic selection of one runnable member.vp -C . <command>selects the root directly.Local and global snapshots cover
vp dev,vp build, andvp preview. Unit tests confirm that all three commands use the same fields and source HTML signal. Other snapshots cover the root fallback, explicit-C, SSR input, and pack--root.The RFC describes these rules.
Fixes #2516.