Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .claude/skills/bump-vite-task/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@ Update the vite-task git dependency in `Cargo.toml` to the latest commit on the

### 5. Run tests

- Run `cargo test -p vite_command -p vite_error -p vite_install -p vite_js_runtime -p vite_migration -p vite_shared -p vite_static_config -p vite-plus-cli -p vite_global_cli` to run the vite-plus crate tests.
- Note: Some tests require network access (e.g., `vite_install::package_manager` tests, `vite_global_cli::commands::env` tests). These may fail in sandboxed environments. Verify they also fail on the main branch before dismissing them.
- Run `cargo test -p vite_command -p vite_error -p vite_pm_cli -p vite_js_runtime -p vite_migration -p vite_shared -p vite_static_config -p vite-plus-cli -p vite_global_cli` to run the vite-plus crate tests.
- Note: Some tests require network access (e.g., `vite_pm_cli::package_manager` tests, `vite_global_cli::commands::env` tests). These may fail in sandboxed environments. Verify they also fail on the main branch before dismissing them.
- Note: `cargo test -p vite_task` will NOT work because vite_task is a git dependency, not a workspace member.
- The PTY snapshot suite (`crates/vite_cli_snapshots`) is excluded from `just test`; it is covered in step 6.

Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -245,14 +245,16 @@ jobs:

# `cargo-nextest` is invoked directly so the job never depends on the
# runner's Rust toolchain.
# Cross-compiled archives may also contain host-built proc-macro tests;
# filter them out before Windows tries to list their ELF binaries.
# --test-threads=1: nextest runs each test in its own process, so
# serial_test's in-process locks no longer serialize tests that contend
# on cross-process shared state (fixed temp paths, e.g.
# `vp-test-custom-home` in vite_shared::home tests). The whole suite is
# only ~1 minute of test time, so full serialization is cheap
# insurance; revisit if it becomes the bottleneck.
- name: Run tests
run: cargo-nextest nextest run --archive-file windows-tests.tar.zst --workspace-remap . --test-threads 1
run: cargo-nextest nextest run -E 'platform(target)' --archive-file windows-tests.tar.zst --workspace-remap . --test-threads 1
env:
RUST_MIN_STACK: '8388608'
# Keep Windows env parity with the `test` recipe in justfile.
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/test-standalone-install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ on:
- 'packages/cli/install.sh'
- 'packages/cli/install.ps1'
- 'crates/vite_installer/**'
- 'crates/vite_pm_cli/**'
- 'crates/vite_setup/**'
- '.github/workflows/test-standalone-install.yml'

Expand Down
7 changes: 3 additions & 4 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,10 @@ vite-plus/
├── crates/vite_command/ # Shared command execution helpers
├── crates/vite_error/ # Shared error types
├── crates/vite_global_cli/ # Standalone global vp binary and top-level command routing
├── crates/vite_install/ # Package-manager detection/install behavior
├── crates/vite_installer/ # Installer binary support
├── crates/vite_js_runtime/ # Managed Node.js runtime support
├── crates/vite_migration/ # Rust migration helpers
├── crates/vite_pm_cli/ # Package-manager command surface
├── crates/vite_pm_cli/ # Package-manager detection, download, command resolution, and dispatch
├── crates/vite_setup/ # Setup helpers
├── crates/vite_shared/ # Shared Rust env config, tracing, output, utilities
├── crates/vite_static_config/ # Static extraction of vite.config.* data
Expand All @@ -52,7 +51,7 @@ vite-plus/
- **JS-backed CLI behavior**: start at `packages/cli/src/bin.ts` and nearby `packages/cli/src/**` files.
- **Local CLI / NAPI-backed behavior**: start at `packages/cli/binding/src/lib.rs` and `packages/cli/binding/src/cli/mod.rs`.
- **Global `vp` routing, aliases, and runtime bootstrap**: start at `crates/vite_global_cli/src/main.rs` and `crates/vite_global_cli/src/cli.rs`.
- **Package-manager commands**: start at `crates/vite_pm_cli/` and `crates/vite_install/`.
- **Package-manager behavior**: start at `crates/vite_pm_cli/`.
- **Managed Node runtime / shims**: start at `crates/vite_js_runtime/`.
- **Static `vite.config.ts` extraction**: start at `crates/vite_static_config/README.md` and `packages/cli/src/resolve-vite-config.ts`.
- **Migration behavior**: `docs/guide/migrate-rules.md`.
Expand Down Expand Up @@ -178,7 +177,7 @@ Use the validation matrix above as the source of truth. For behavior-bearing cha
- Use `vp help` and `vp <command> --help` to inspect command surfaces.
- For command routing bugs, compare the global path (`crates/vite_global_cli/`) with the local/NAPI path (`packages/cli/src/bin.ts`, `packages/cli/binding/`).
- For config-loading bugs, compare the static extractor (`crates/vite_static_config/`) with the JS resolver fallback (`packages/cli/src/resolve-vite-config.ts`).
- For package-manager behavior, inspect `crates/vite_pm_cli/`, `crates/vite_install/`, and related PTY snapshot cases.
- For package-manager behavior, inspect `crates/vite_pm_cli/` and related PTY snapshot cases.
- For `vp check`, lint, format, or type-check behavior, validate end-to-end because bundled-tool routing can hide silent config drift.

## AI Assistant Tips
Expand Down
69 changes: 32 additions & 37 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
"css-module-lexer",
"html5gum",
"prettyplease",
"proc-macro2",

Check warning on line 11 in Cargo.toml

View workflow job for this annotation

GitHub Actions / Lint

shear/redundant_ignore

redundant ignore `proc-macro2` (remove from ignored list)
"quote",

Check warning on line 12 in Cargo.toml

View workflow job for this annotation

GitHub Actions / Lint

shear/redundant_ignore

redundant ignore `quote` (remove from ignored list)
"rolldown_filter_analyzer",
"rolldown_plugin_vite_asset",
"rolldown_plugin_vite_asset_import_meta_url",
Expand All @@ -18,7 +18,7 @@
"rolldown_plugin_vite_html",
"rolldown_plugin_vite_html_inline_proxy",
"string_cache",
"syn",

Check warning on line 21 in Cargo.toml

View workflow job for this annotation

GitHub Actions / Lint

shear/redundant_ignore

redundant ignore `syn` (remove from ignored list)
]

[workspace.package]
Expand Down Expand Up @@ -299,9 +299,9 @@
vite_command = { path = "crates/vite_command" }
vite_error = { path = "crates/vite_error" }
vite_js_runtime = { path = "crates/vite_js_runtime" }
vite_install = { path = "crates/vite_install" }
vite_migration = { path = "crates/vite_migration" }
vite_pm_cli = { path = "crates/vite_pm_cli" }
vite_pm_cli_macros = { path = "crates/vite_pm_cli_macros" }
vite_setup = { path = "crates/vite_setup" }
vite_shared = { path = "crates/vite_shared" }
vite_static_config = { path = "crates/vite_static_config" }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ added 1 package in <duration>
should add packages to dependencies

```
warn: npm does not support --allow-build.

added 1 package in <duration>
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ added 3 packages in <duration>
should add @vite-plus-test/utils to workspace root

```
warn: npm does not support --workspace.

up to date in <duration>
```
Expand Down Expand Up @@ -114,6 +115,7 @@ added 1 package in <duration>
should add @vite-plus-test/utils to packages/app

```
warn: npm does not support --workspace.

up to date in <duration>
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ added 1 package in <duration>
should add packages to dependencies

```
warn: npm does not support --allow-build.

added 1 package in <duration>
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ added 3 packages in <duration>
should add @vite-plus-test/utils to workspace root

```
warn: npm does not support --workspace.

up to date in <duration>
```
Expand Down Expand Up @@ -114,6 +115,7 @@ added 1 package in <duration>
should add @vite-plus-test/utils to packages/app

```
warn: npm does not support --workspace.

up to date in <duration>
```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ should error because save-catalog is not supported at pnpm@9
**Exit code:** 1

```
 ERROR  Unknown option: 'save-catalog-name'
Did you mean 'save-optional'? Use "--config.unknown=value" to force an unknown option.
 ERROR  Unknown option: 'save-catalog'
Did you mean 'save-exact', or 'save-prod'? Use "--config.unknown=value" to force an unknown option.
For help, run: pnpm help add
```
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ should add package as dev dependencies
should add packages to dependencies

```
warn: yarn does not support --allow-build.
➤ YN0000: · Yarn <version>
➤ YN0000: ┌ Resolution step
➤ YN0085: │ + test-vite-plus-install@npm:1.0.0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ should add package to workspace root
should add @vite-plus-test/utils to workspace root

```
warn: yarn does not support --workspace.
➤ YN0000: · Yarn <version>
➤ YN0000: ┌ Resolution step
➤ YN0000: └ Completed
Expand Down Expand Up @@ -140,6 +141,7 @@ Done in <duration> <duration>
should add @vite-plus-test/utils to packages/app

```
warn: yarn does not support --workspace.
[app]: Process started
[app]: ➤ YN0000: · Yarn <version>
[app]: ➤ YN0000: ┌ Resolution step
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ VITE+ - The Unified Toolchain for the Web

Usage: vp dlx [OPTIONS] <ARGS>...

Execute a package binary without installing it
Download and execute a package without installing it globally

Arguments:
<ARGS>... Package to execute and arguments
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ VITE+ - The Unified Toolchain for the Web

Usage: vp dlx [OPTIONS] <ARGS>...

Execute a package binary without installing it
Download and execute a package without installing it globally

Arguments:
<ARGS>... Package to execute and arguments
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ VITE+ - The Unified Toolchain for the Web

Usage: vp dlx [OPTIONS] <ARGS>...

Execute a package binary without installing it
Download and execute a package without installing it globally

Arguments:
<ARGS>... Package to execute and arguments
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
should show help message

```
Execute a package binary without installing it
Download and execute a package without installing it globally

Usage: vp dlx [OPTIONS] <ARGS>...

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ VITE+ - The Unified Toolchain for the Web

Usage: vp dlx [OPTIONS] <ARGS>...

Execute a package binary without installing it
Download and execute a package without installing it globally

Arguments:
<ARGS>... Package to execute and arguments
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ VITE+ - The Unified Toolchain for the Web

Usage: vp dlx [OPTIONS] <ARGS>...

Execute a package binary without installing it
Download and execute a package without installing it globally

Arguments:
<ARGS>... Package to execute and arguments
Expand Down
Loading
Loading