| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
✅ Deploy Preview for viteplus-preview ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Sorry, something went wrong.
CLI artifact sizes (fd33292)Final release artifacts built by the canonical build-upstream and build-windows-cli actions.
|
Sorry, something went wrong.
|
Codex Review: Didn't find any major issues. Keep it up! Reviewed commit: 67ab1181e1 ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Sorry, something went wrong.
Registry bridge build (fd33292)This commit build is published to the registry bridge, which serves these as ordinary npm versions (every other package proxies to npmjs):
Install the Vite+ CLI built from this commit, then migrate a project: # macOS / Linux
curl -fsSL https://raw.githubusercontent.com/voidzero-dev/vite-plus/fd332923578a5349f99ca6441856b6c80d94f058/packages/cli/install.sh | VP_PR_VERSION=2523 bash# Windows (PowerShell)
$env:VP_PR_VERSION="2523"; irm https://raw.githubusercontent.com/voidzero-dev/vite-plus/fd332923578a5349f99ca6441856b6c80d94f058/packages/cli/install.ps1 | iexOr download the standalone Windows installer built from this commit:
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.fd332923578a5349f99ca6441856b6c80d94f058" --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/:
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.fd332923578a5349f99ca6441856b6c80d94f058",
"vite": "npm:@voidzero-dev/vite-plus-core@0.0.0-commit.fd332923578a5349f99ca6441856b6c80d94f058"
}
} |
Sorry, something went wrong.
🐳 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-2523 2>/dev/null; docker pull ghcr.io/voidzero-dev/vite-plus:pr-2523Quick check: docker run --rm ghcr.io/voidzero-dev/vite-plus:pr-2523 vp --versionSee docs/guide/docker.md for usage. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Move argument parsing for the staged, config, hooks, migrate, and create commands from JavaScript to Rust. Each NAPI parser uses clap for strict validation and returns a typed result to JavaScript.
Call graph
process.argv | v local Node.js CLI packages/cli/src/bin.ts | | raw arguments for one JavaScript command v NAPI parser function packages/cli/binding/src/js_command_args/ | v clap command grammar | +-- checks aliases and option boundaries +-- converts values +-- checks explicit negation +-- rejects unknown options +-- rejects invalid positional arguments | v validated Rust arguments | v typed NAPI parse outcome | v JavaScript command operationsJavaScript sends raw arguments to one NAPI parser. JavaScript does not parse the returned values again.
The Rust parsers print command help through the shared vp_cli_help formatter. The global and local CLI paths use the same help format. The create parser keeps all template arguments after the separator in their original order.
This change removes duplicate JavaScript option data and the direct mri dependency. The RFC defines the parser rules, help synchronization, NAPI result types, and command ownership.
Compatibility
Argument parsing is now strict. The CLI rejects unknown options and extra positional arguments. It rejects unsupported negative string options and repeated scalar options.
The staged command rejects invalid concurrency values. It also rejects empty --cwd, --diff, and --diff-filter values before JavaScript runs.
The create command rejects --all and invalid package-manager values. These inputs could pass through mri or fail later in JavaScript.
Performance
The benchmark compares the base commit 45acff9b4 with this branch. It ran on macOS ARM64 with Node.js 22.22.0.
Each CLI result used 25 to 30 alternating paired runs after four warm-up pairs. A negative change is faster.
The parser-only test used vp staged --allow-empty --concurrent=2 --diff-filter ACMR --no-stash.
The clap/NAPI parser is 5.3 times slower in isolation. This adds about 5 µs to a CLI process that takes 130 to 155 ms.
The CLI calls the parser one time. The complete CLI path has no measurable regression. Help is 1% to 4% faster.
vp config --hooks-dir is not a parser-only comparison. The base command starts hooks validation. The PR rejects the missing value first.
Unknown-option timings are not comparable. The base parser can accept an unknown option and start command work. The PR rejects it during parsing.