You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 2e1cde5
Browse filesBrowse the repository at this point in the historyBrowse files
fix: preserve package-manager management when opting out of Node.js (#147)
`node-manager: false` currently runs unscoped `vp env off`, which also
disables package-manager management in Vite+ 0.3.1+. Passing
`VP_NODE_MANAGER=no` to the refactored installer has the same side
effect.
Configure Node.js after installation with `vp env off node` on Vite+
0.3.1+, falling back to `vp env off` on older versions. Stop injecting
`VP_NODE_MANAGER` in GitHub, GitLab, and Azure. `true` and unset now
leave the installer default unchanged instead of force-enabling
management.
🤖 Generated with Codex
| `version` | Version of Vite+ to install. Takes precedence over `version-file` | No | auto / `latest` |
347
+
| `version-file` | Path to a file to resolve the Vite+ version from (`package.json`, `pnpm-workspace.yaml`, or `.yarnrc.yml`) | No | |
348
+
| `node-version` | Node.js version to install via `vp env use` | No | Vite+ resolution |
349
+
| `node-version-file` | Path to file containing Node.js version (`.nvmrc`, `.node-version`, `.tool-versions`, `package.json`) | No | |
350
+
| `node-manager` | Control Vite+'s Node.js manager: `false`keeps the runner's Node.js, `true` leaves the installer default unchanged | No | Auto (on for CI) |
351
+
| `working-directory` | Project directory used for relative paths, lockfile auto-detection, environment checks, and default install | No | Workspace root |
352
+
| `run-install` | Run `vp install` after setup. Accepts boolean or YAML object with `cwd`/`args` | No | `true` |
353
+
| `sfw` | Wrap `vp install` with [Socket Firewall Free](https://docs.socket.dev/docs/socket-firewall-free) (`sfw`) | No | `false` |
354
+
| `cache` | Enable caching of project dependencies | No | `false` |
355
+
| `cache-save` | Save the dependency cache in the post action. Has no effect when `cache` is `false` | No | `true` |
356
+
| `cache-dependency-path` | Path to lock file for cache key generation | No | Auto-detected |
357
+
| `registry-url` | Optional registry to set up for auth. Sets the registry in `.npmrc` and reads auth from `NODE_AUTH_TOKEN` | No | |
358
+
| `scope` | Optional scope for scoped registries. Falls back to repo owner for GitHub Packages | No | |
359
359
360
360
When `working-directory` is set, relative `run-install.cwd`, `node-version-file`, `version-file`, and `cache-dependency-path` values are resolved from that directory.
361
361
362
362
Omitting both `node-version` and `node-version-file` leaves the session without an override. With the Vite+ Node.js manager enabled, its shims search the current directory and its parents for `.node-version`, `package.json#devEngines.runtime`, `package.json#engines.node`, and `.nvmrc`, in that order. If the project does not declare a version, Vite+ uses the user-level default. Set this default with `vp env default <version>`. If no user-level default exists, Vite+ uses the latest LTS release.
363
363
364
364
`working-directory`applies to the action. Each later workflow step keeps its own working directory. Vite+ searches for Node.js version sources from each command's current working directory. For a subproject, set `working-directory` on the step that runs `node` or `vp`.
365
365
366
-
`node-manager: false` skips Node.js shim creation and runs `vp env off`, so `vp` commands prefer the Node.js already on `PATH`. It cannot be combined with `node-version` or `node-version-file`.
366
+
`node-manager: false` runs `vp env off node` (Vite+ 0.3.1+; `vp env off` on older versions), so `vp` commands prefer the Node.js already on `PATH`. It cannot be combined with `node-version` or `node-version-file`.
| `node-manager` | String input: `"false"`keeps the runner image's Node.js (skips shims and runs `vp env off`); `"true"` force-enables the managed Node.js; empty lets the installer decide (enabled on CI) | |
549
-
| `registry-url` | Optional registry URL to write to a temporary `.npmrc` | |
550
-
| `scope` | Optional scope for authenticating against scoped registries | |
551
-
| `setup-ref` | setup-vp ref used to download the GitLab bootstrap and compiled runtime. Always set it to the same tag as the remote URL; the default is the latest release when the template was published | `v1.19.0` |
| `node-manager` | String input: `"false"`keeps the runner image's Node.js (disables Node.js management after installation); `"true"` leaves the installer default unchanged; empty lets the installer decide (enabled on CI) | |
549
+
| `registry-url` | Optional registry URL to write to a temporary `.npmrc` | |
550
+
| `scope` | Optional scope for authenticating against scoped registries | |
551
+
| `setup-ref` | setup-vp ref used to download the GitLab bootstrap and compiled runtime. Always set it to the same tag as the remote URL; the default is the latest release when the template was published | `v1.19.0` |
552
552
553
553
### GitLab Notes
554
554
@@ -610,7 +610,7 @@ Pin `ref` and `setupRef` to the same exact tag or commit SHA. Do not use the `v1
610
610
| `scope` | | Optional npm registry scope. |
611
611
| `setupRef` | `v1.19.0` | Ref used to download bootstrap scripts and `dist/azure/index.mjs`. Always set it to the same tag as `ref`; the default is the latest release when the template was published. |
612
612
| `nodeVersion` | `24.x` | Passed to `UseNode@1`; an empty string skips Node setup. |
613
-
| `nodeManager` | | Control Vite+'s Node.js manager: `false`keeps the agent's Node.js (e.g. from `UseNode@1`); `true` force-enables the managed one; empty lets the installer decide. |
613
+
| `nodeManager` | | Control Vite+'s Node.js manager: `false`keeps the agent's Node.js (e.g. from `UseNode@1`); `true` leaves the installer default unchanged; empty lets the installer decide. |
614
614
| `cache` | `false` | Enable Azure `Cache@2` around the package-manager cache directory. |
Copy file name to clipboardExpand all lines: action.yml
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -28,7 +28,7 @@ inputs:
28
28
description: "Path to file containing the Node.js version spec (.nvmrc, .node-version, .tool-versions, package.json). Ignored when node-version is specified."
29
29
required: false
30
30
node-manager:
31
-
description: "Control Vite+'s Node.js version manager. When unset, the Vite+ installer decides (enabled on CI). Set to `false` to keep the Node.js already on the runner (e.g. from actions/setup-node or the runner image): shim creation is skipped and vp commands prefer the system Node.js. Set to `true` to force-enable the managed Node.js. Cannot be `false` together with node-version or node-version-file."
31
+
description: "Control Vite+'s Node.js version manager. When unset, the Vite+ installer decides (enabled on CI). Set to `false` to keep the Node.js already on the runner (e.g. from actions/setup-node or the runner image): after installation, vp commands prefer the system Node.js. Set to `true` to leave the installer default unchanged. Cannot be `false` together with node-version or node-version-file."
32
32
required: false
33
33
working-directory:
34
34
description: "Project directory to use for relative paths, lockfile auto-detection, environment checks, and default `vp install` execution."
0 commit comments