Skip to content

chore: bump vite-task to 7d69d65 - #2813

Merged
wan9chi merged 3 commits into
mainfrom
chore/bump-vite-task-7d69d65
Sep 25, 2026
Merged

wan9chi merged 3 commits into
mainfrom
chore/bump-vite-task-7d69d65

Conversation

@wan9chi

@wan9chi wan9chi commented Sep 25, 2026 •

Copy link
Copy Markdown
Member

Bumps vite-task from 790b152 to 7d69d65.

Changelog: voidzero-dev/vite-task@790b152...7d69d65#diff-06572a96a58dc510037d5efa622f9bec8519bc1beab13c9f251e97e657a9d4ed

Changes from vite-task

  • Changed A task's cache settings now go inside cache, e.g. cache: { env: ["NODE_ENV"], input: ["src/**"] }. cache: true is the same as cache: {}. Top-level env, untrackedEnv, input, and output are rejected with an error that points to vp migrate (voidzero-dev/vite-task#749).
  • Fixed On Windows, environment variable names used by vp run match regardless of ASCII letter case (voidzero-dev/vite-task#747).
  • Fixed Cached tasks on macOS no longer intermittently fail with oils I/O error (main): No such process (voidzero-dev/vite-task#703).

Changes in this PR

  • Session::init_with, ScriptCommand::envs, and SyntheticPlanRequest::envs now key environment variables by vt_casefold::EnvName. The vite-plus-cli env maps use the same key type (EnvMap), so PATH lookup and env merging follow the platform rules. The hand-written case-insensitive PATH lookups are replaced by vt::get_path_env.
  • Adds vt_casefold as a workspace dependency, including the commented local [patch] entry.
  • Regenerates packages/cli/src/run-config.ts.
  • Moves top-level task cache fields under cache in CLI snapshot fixtures and a vp_static_config test.
  • Keeps docs/vite.config.ts in the old format. Docs deploys build it with the released vp from setup-vp, and that version rejects a cache object. feat(migrate): move task cache settings under cache #2814 pins that vp version for docs builds, so the first release with this vite-task doesn't break them.
  • Documents the cache object in docs/config/run.md. env, untrackedEnv, input, and output become cache.env, cache.untrackedEnv, cache.input, and cache.output. Updates the examples and links in the cache, run, and automatic data tracking guides and the READMEs. The docs describe only the cache object and don't mention the old top-level fields.

vp migrate support for moving these fields comes in the next PR in this stack.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Sep 25, 2026 •

Copy link
Copy Markdown

🚀 Deploying Preview to Cloudflare 🚀

Preview URL: https://chore-bump-vite-task-7d69d65-viteplus-dev.voidzero-docs.workers.dev (commit 5029282)

This URL reflects your latest Preview deployment

Preview Deployments by commit

Status Deployment URL Commit Updated (UTC) See this deployment's details
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://16c86930-viteplus-dev.voidzero-docs.workers.dev 5029282 2026-09-25T05:42:26.954Z Visit the dashboard ↗
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://f1d6cba8-viteplus-dev.voidzero-docs.workers.dev c75f509 2026-09-25T04:21:22.313Z Visit the dashboard ↗
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://e4130e42-viteplus-dev.voidzero-docs.workers.dev 89aa969 2026-09-25T03:53:28.844Z Visit the dashboard ↗

@github-actions

github-actions Bot commented Sep 25, 2026 •

Copy link
Copy Markdown
Contributor

CLI artifact sizes (5029282)

Final release artifacts built by the canonical build-upstream and build-windows-cli actions.
The dist rows use the Linux build. The core total excludes .node files to match the release artifact.

Artifact Format Base PR Change
packages/cli/dist Directory total 2.34 MiB 2.34 MiB +210 B (+0.01%)
packages/core/dist Directory total 3.95 MiB 3.95 MiB 0 B (0.00%)
Combined package dist Directory total 6.30 MiB 6.30 MiB +210 B (+0.00%)
vp (Linux x64) Binary 11.29 MiB 11.29 MiB 0 B (0.00%)
vp (Linux x64) gzip -9 4.88 MiB 4.88 MiB -348 B (-0.01%)
NAPI (Linux x64) Binary 32.16 MiB 32.19 MiB +32.00 KiB (+0.10%)
NAPI (Linux x64) gzip -9 12.74 MiB 12.76 MiB +18.86 KiB (+0.14%)
vp (macOS ARM64) Binary 8.41 MiB 8.41 MiB +16 B (+0.00%)
vp (macOS ARM64) gzip -9 4.26 MiB 4.26 MiB -1.17 KiB (-0.03%)
NAPI (macOS ARM64) Binary 39.75 MiB 39.80 MiB +48.41 KiB (+0.12%)
NAPI (macOS ARM64) gzip -9 17.05 MiB 17.07 MiB +14.77 KiB (+0.08%)
vp (Windows x64) Binary 9.16 MiB 9.15 MiB -3.00 KiB (-0.03%)
vp (Windows x64) gzip -9 4.00 MiB 4.00 MiB -3.59 KiB (-0.09%)
NAPI (Windows x64) Binary 27.11 MiB 27.15 MiB +39.50 KiB (+0.14%)
NAPI (Windows x64) gzip -9 10.85 MiB 10.87 MiB +17.34 KiB (+0.16%)
Trampoline (Windows x64) Binary 13.50 KiB 13.50 KiB 0 B (0.00%)
Trampoline (Windows x64) gzip -9 7.08 KiB 7.09 KiB +3 B (+0.04%)
Installer (Windows x64) Binary 4.56 MiB 4.56 MiB 0 B (0.00%)
Installer (Windows x64) gzip -9 2.13 MiB 2.13 MiB +2 B (+0.00%)

@github-actions

github-actions Bot commented Sep 25, 2026 •

Copy link
Copy Markdown
Contributor

✅ Staging deployment successful!

Preview: https://viteplus-staging.void.app/
Commit: 5029282

@wan9chi
wan9chi added this pull request to stack #2815 September 25, 2026 04:29
@wan9chi
wan9chi merged commit 70185af into main Sep 25, 2026
57 checks passed
@wan9chi
wan9chi deleted the chore/bump-vite-task-7d69d65 branch September 25, 2026 09:47
wan9chi added a commit that referenced this pull request Sep 25, 2026
Stacked on #2813, which bumps vite-task to a version that rejects `env`,
`untrackedEnv`, `input`, and `output` at the top level of a task. Its
error message tells users to run `vp migrate`; this PR makes that work.

## What `vp migrate` does

It moves those four settings into the task's `cache` object in static
`run.tasks` objects in `vite.config.*`, including configs wrapped in
`satisfies` or `as`. This runs on fresh migrations and on existing Vite+
projects without `--full`, for the workspace root and every workspace
package.

| Before | After |
| ------------------------------------------------- |
------------------------------------------------- |
| `build: { command, env: [...] }` | `build: { command, cache: { env:
[...] } }` |
| `build: { command, cache: true, input: [...] }` | `build: { command,
cache: { input: [...] } }` |
| `build: { cache: { env: [...] }, output: [...] }` | `build: { cache: {
env: [...], output: [...] } }` |

- The new `cache` object takes the position of the first moved setting,
or of an existing `cache: true`.
- Moved settings keep their text and indentation. The formatting step
that runs after a migration indents them inside `cache`. Like the pack
config migration, the edit doesn't try to format the file itself.
- Comments on their own line above a moved setting, and `//` comments
after it on the same line, move with it.
- The rewrite does not evaluate config code. It leaves a task unchanged
and adds a warning with a link to `/config/run#cache` for:
  - spreads, or computed, escaped, or duplicate keys;
  - a moved setting written as a method;
- a comment between a moved setting and its comma, or after the last
setting in `cache`;
  - a moved setting that already exists in `cache`;
- `cache: false`, a shorthand `cache`, or any other non-literal `cache`
value.
- On an existing Vite+ project, these warnings don't count as a
migration. When nothing else changes, `vp migrate` prints them and then
"This project is already using Vite+!".

The migration summary gets a ``Task cache settings moved under `cache`
`` line and counts the change as a config update.

## Implementation

- `crates/vp_migration/src/task_cache.rs`: the AST rewrite and its unit
tests. It returns the updated content and the tasks that need manual
changes.
- `packages/cli/binding/src/migration.rs`: exposes it as
`migrateTaskCacheConfig`.
- `packages/cli/src/migration`: `migrateTaskCacheConfigInViteConfig`
runs next to the `lazyPlugins` wrapping in the standalone, monorepo, and
`rewriteMonorepoProject` paths. On existing Vite+ projects it runs in
`finalizeCoreMigrationForExistingVitePlus`, which reports
`taskCacheConfig` and returns the warnings in `taskCacheWarnings`.
`bin.ts` adds them to the report only after the up-to-date check.
- New `migration_task_cache_fields` snapshot fixture. It covers a
migration followed by a second, unchanged run, and the manual-review
warnings, including a rerun on the up-to-date project.
- Docs: a "Task Cache Configuration" section in
`docs/guide/migrate-rules.md`.

## Docs builds

The docs site is built with the released `vp` from `setup-vp`, not with
this repo's build. `docs/vite.config.ts` keeps the old task format that
`1.0.0-rc.0` accepts, because no format works with both that release and
the new vite-task. Until now `setup-vp` installed the latest release, so
the first release with the new vite-task would have broken docs deploys
and previews. This PR pins `version: 1.0.0-rc.0` in
`.github/actions/deploy-docs/action.yml` and
`.github/workflows/build-docs-fork-preview.yml`.

Follow-up after the release becomes npm `latest`: remove both pins and
move the `build:site` settings under `cache` in one PR. That PR's
`staging-deploy` check builds the docs with the new release and the
converted config.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants