Skip to content

feat(env)!: manage package manager environments - #2398

Merged
fengmk2 merged 38 commits into
voidzero-dev:mainfrom
liangmiQwQ:feat-breaking/extend-vp-env-to-manage-pm
Aug 31, 2026
Merged

feat(env)!: manage package manager environments#2398
fengmk2 merged 38 commits into
voidzero-dev:mainfrom
liangmiQwQ:feat-breaking/extend-vp-env-to-manage-pm

Conversation

@liangmiQwQ

@liangmiQwQ liangmiQwQ commented Aug 10, 2026

Copy link
Copy Markdown
Collaborator

Depends on #2391. Close #1853

This PR extends vp env to manage Node.js and package managers as peer environment components.

It adds package-manager defaults, session overrides, project pins, installation lifecycle, diagnostics, listings, and scoped environment commands. Resolution follows explicit/session overrides, project declarations, lockfile or config detection, and the global default. npm, pnpm, Yarn, and Bun remain independent families, including their aliases.

Node and package-manager modes can be managed independently. Scoped commands avoid resolving excluded families, and exact integrity pins survive project resolution, vp env use, session overrides, installation, and shim execution.

It doesn't break users' daily use command, commands such as vp env default 22.19.0 still works.

Breaking changes: unscoped component commands now operate on the complete environment, and the JSON contracts for current, list, and list-remote expose Node.js and package managers as peer components.

🤖 Generated with Codex

@netlify

netlify Bot commented Aug 10, 2026

Copy link
Copy Markdown

Deploy Preview for viteplus-preview canceled.

Name Link
🔨 Latest commit 880fea3
🔍 Latest deploy log https://app.netlify.com/projects/viteplus-preview/deploys/6a94cd2b64972b000764d9d6

@liangmiQwQ
liangmiQwQ force-pushed the feat-breaking/extend-vp-env-to-manage-pm branch 16 times, most recently from 7737c90 to 4d9fd9e Compare August 12, 2026 01:07
@liangmiQwQ
liangmiQwQ force-pushed the feat-breaking/extend-vp-env-to-manage-pm branch 2 times, most recently from a9d9f6c to 447f600 Compare August 12, 2026 05:47
@liangmiQwQ
liangmiQwQ marked this pull request as ready for review August 12, 2026 13:16
@liangmiQwQ
liangmiQwQ requested a review from fengmk2 August 13, 2026 01:13
@liangmiQwQ
liangmiQwQ force-pushed the feat-breaking/extend-vp-env-to-manage-pm branch from 0181e80 to df7f7a6 Compare August 15, 2026 12:31
@liangmiQwQ
liangmiQwQ marked this pull request as draft August 19, 2026 14:25
@liangmiQwQ
liangmiQwQ force-pushed the feat-breaking/extend-vp-env-to-manage-pm branch 3 times, most recently from f592c87 to de92623 Compare August 21, 2026 03:14
@liangmiQwQ
liangmiQwQ force-pushed the feat-breaking/extend-vp-env-to-manage-pm branch from 2a6acd0 to a1a4538 Compare August 28, 2026 10:53

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 1788ae2b29

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

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".

Comment thread crates/vp_global_cli/src/commands/env/current.rs Outdated
Comment thread crates/vp_global_cli/src/commands/env/lifecycle.rs Outdated
Comment thread crates/vp_global_cli/src/commands/env/use.rs Outdated
Comment thread crates/vp_global_cli/src/commands/env/use.rs Outdated
Comment thread crates/vp_global_cli/src/shim/dispatch.rs
@liangmiQwQ

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 80e29560a3

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

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".

Comment thread crates/vp_global_cli/src/commands/env/config.rs
Comment thread crates/vp_global_cli/src/commands/env/mod.rs Outdated
Comment thread crates/vp_global_cli/src/commands/env/clean.rs Outdated
Comment thread crates/vp_global_cli/src/commands/env/exec.rs Outdated
@liangmiQwQ

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9c79b9d41c

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

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".

Comment thread crates/vp_global_cli/src/commands/env/spec.rs Outdated
Comment thread crates/vp_global_cli/src/commands/env/which.rs Outdated
Comment thread crates/vp_global_cli/src/shim/dispatch.rs Outdated
Comment thread crates/vp_global_cli/src/commands/env/config.rs
Comment thread crates/vp_global_cli/src/commands/env/use.rs Outdated
Comment thread crates/vp_global_cli/src/commands/env/doctor.rs Outdated
@liangmiQwQ
liangmiQwQ marked this pull request as ready for review August 30, 2026 14:16
@liangmiQwQ

Copy link
Copy Markdown
Collaborator Author

@fengmk2 I'm ready if CI is green

@fengmk2 fengmk2 added preview-build Publish this PR's commits to the registry bridge as preview builds and removed preview-build Publish this PR's commits to the registry bridge as preview builds labels Aug 30, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Registry bridge build (a2a87c8)

Warning

This build is from the fork liangmiQwQ/vite-plus and has not been reviewed.
Installing it runs that code on your machine. Build log

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

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

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

@liangmiQwQ

Copy link
Copy Markdown
Collaborator Author

2c9c326 is just a test-only commit, so no behavior change, no rebuild needed.

Comment thread docs/guide/env.md
@liangmiQwQ

Copy link
Copy Markdown
Collaborator Author

Screenshot
image

@liangmiQwQ
liangmiQwQ requested a review from fengmk2 August 31, 2026 00:10
Comment thread crates/vp_global_cli/src/commands/env/current.rs
@fengmk2
fengmk2 merged commit 3124145 into voidzero-dev:main Aug 31, 2026
128 checks passed
@liangmiQwQ
liangmiQwQ deleted the feat-breaking/extend-vp-env-to-manage-pm branch August 31, 2026 03:14
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.

Option To Change Package Manager

2 participants