Skip to content

fix(implode): clean long paths on Windows - #2510

Merged
fengmk2 merged 2 commits into
mainfrom
fix/implode-windows-long-paths
Aug 21, 2026
Merged

fix(implode): clean long paths on Windows#2510
fengmk2 merged 2 commits into
mainfrom
fix/implode-windows-long-paths

Conversation

@fengmk2

@fengmk2 fengmk2 commented Aug 20, 2026

Copy link
Copy Markdown
Member

This change fixes #2502.

On Windows, vp implode now starts a native cleanup helper from a temporary executable. The helper waits for the original process. It removes only the renamed Vite+ root. It retries the operation when Windows locks a file. It writes an error log if it cannot remove the root.

PowerShell now removes only the temporary helper executable. It does not traverse the Vite+ data tree.

Rust tests cover long paths, locked files, junctions, and an immediate reinstall. The Windows standalone install workflow tests monolithic and split layouts.

@netlify

netlify Bot commented Aug 20, 2026

Copy link
Copy Markdown

Deploy Preview for viteplus-preview canceled.

Name Link
🔨 Latest commit 8ed9517
🔍 Latest deploy log https://app.netlify.com/projects/viteplus-preview/deploys/6a87cb9ff4a86f0008777a50

@github-actions

github-actions Bot commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

Native binary sizes (8ed9517)

Final release artifacts built by the canonical build-upstream and build-windows-cli actions.

Artifact Format Base PR Change
vp (Linux x64) Binary 10.69 MiB 10.69 MiB 0 B (0.00%)
vp (Linux x64) gzip -9 4.63 MiB 4.63 MiB +4 B (+0.00%)
NAPI (Linux x64) Binary 32.19 MiB 32.19 MiB 0 B (0.00%)
NAPI (Linux x64) gzip -9 12.69 MiB 12.69 MiB 0 B (0.00%)
vp (macOS ARM64) Binary 7.98 MiB 7.98 MiB 0 B (0.00%)
vp (macOS ARM64) gzip -9 4.04 MiB 4.04 MiB +9 B (+0.00%)
NAPI (macOS ARM64) Binary 39.79 MiB 39.79 MiB 0 B (0.00%)
NAPI (macOS ARM64) gzip -9 16.98 MiB 16.98 MiB 0 B (0.00%)
vp (Windows x64) Binary 8.58 MiB 8.59 MiB +5.50 KiB (+0.06%)
vp (Windows x64) gzip -9 3.74 MiB 3.75 MiB +4.06 KiB (+0.11%)
NAPI (Windows x64) Binary 27.03 MiB 27.03 MiB 0 B (0.00%)
NAPI (Windows x64) gzip -9 10.75 MiB 10.75 MiB +3 B (+0.00%)
Trampoline (Windows x64) Binary 216.50 KiB 216.50 KiB 0 B (0.00%)
Trampoline (Windows x64) gzip -9 104.34 KiB 104.34 KiB 0 B (0.00%)
Installer (Windows x64) Binary 4.48 MiB 4.48 MiB 0 B (0.00%)
Installer (Windows x64) gzip -9 2.10 MiB 2.10 MiB -1 B (-0.00%)

@fengmk2
fengmk2 marked this pull request as ready for review August 20, 2026 11:43
@fengmk2 fengmk2 self-assigned this Aug 20, 2026
@fengmk2
fengmk2 requested a review from wan9chi August 20, 2026 11:43
@fengmk2 fengmk2 added the preview-build Publish this PR's commits to the registry bridge as preview builds label Aug 20, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Registry bridge build (b3de9bd)

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.b3de9bd37039847cb262ea7bc99a4bf3bdf8ef45
@voidzero-dev/vite-plus-core 0.0.0-commit.b3de9bd37039847cb262ea7bc99a4bf3bdf8ef45

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

# macOS / Linux
curl -fsSL https://raw.githubusercontent.com/voidzero-dev/vite-plus/b3de9bd37039847cb262ea7bc99a4bf3bdf8ef45/packages/cli/install.sh | VP_PR_VERSION=2510 bash
# Windows (PowerShell)
$env:VP_PR_VERSION="2510"; irm https://raw.githubusercontent.com/voidzero-dev/vite-plus/b3de9bd37039847cb262ea7bc99a4bf3bdf8ef45/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.b3de9bd37039847cb262ea7bc99a4bf3bdf8ef45" --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.b3de9bd37039847cb262ea7bc99a4bf3bdf8ef45",
    "vite": "npm:@voidzero-dev/vite-plus-core@0.0.0-commit.b3de9bd37039847cb262ea7bc99a4bf3bdf8ef45"
  }
}

@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-2510 236MB
# remove any stale local copy from a previous run, then pull fresh
docker rmi ghcr.io/voidzero-dev/vite-plus:pr-2510 2>/dev/null; docker pull ghcr.io/voidzero-dev/vite-plus:pr-2510

Quick check:

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

See docs/guide/docker.md for usage.

@fengmk2
fengmk2 requested a review from cpojer August 21, 2026 01:21
@fengmk2
fengmk2 force-pushed the fix/implode-windows-long-paths branch from 860f78e to e221000 Compare August 21, 2026 03:09
@fengmk2
fengmk2 force-pushed the fix/implode-windows-long-paths branch from e221000 to 8ed9517 Compare August 21, 2026 03:53
@fengmk2
fengmk2 merged commit 2e9eda4 into main Aug 21, 2026
67 checks passed
@fengmk2
fengmk2 deleted the fix/implode-windows-long-paths branch August 21, 2026 05:12
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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Windows: deferred implode cleanup leaves payloads with paths over 260 characters

2 participants