void 0.10.5 → 0.10.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agents-Bmr5tFFb.mjs +1454 -0
- package/dist/{auth-cmd-UoCwfDQv.mjs → auth-cmd-DlgNwByu.mjs} +10 -10
- package/dist/{better-auth-shared-D0Mbmx5V.mjs → better-auth-shared-BQooDxbw.mjs} +1 -1
- package/dist/{better-auth-shared-jkksALri.d.mts → better-auth-shared-BvnM9px6.d.mts} +2 -2
- package/dist/{build-cmd-CVyuBHjP.mjs → build-cmd-Br8qL0rA.mjs} +15 -17
- package/dist/{cache-ACORQCIq.mjs → cache-wH-mP8UE.mjs} +10 -12
- package/dist/{cancel-deploy-Gi8zmoZC.mjs → cancel-deploy-BEBOEgtu.mjs} +16 -18
- package/dist/cli/cli.mjs +47 -49
- package/dist/{client-BlbnA92X.mjs → client-Cj96iiBH.mjs} +74 -8
- package/dist/{config-8dLIngKW.mjs → config-1twldYCW.mjs} +10 -10
- package/dist/{config-CbJS4Krx.mjs → config-BdUctCZD.mjs} +4 -4
- package/dist/{create-project-LjvkYziS.mjs → create-project-DD9n8Ho-.mjs} +28 -23
- package/dist/{db-C00yjN01.mjs → db-DjKE2-A-.mjs} +147 -149
- package/dist/{delete-CplfvTgU.mjs → delete-D2kr3Kmk.mjs} +13 -15
- package/dist/{deploy-CISNL5uK.mjs → deploy-C4PbkFyE.mjs} +97 -100
- package/dist/{discover-ZWuBvt22.mjs → discover-BuVVSAum.mjs} +3 -3
- package/dist/{dist-5cGIJHQQ.mjs → dist-BuiRJkTd.mjs} +59 -27
- package/dist/{domain-B4HpcgNG.mjs → domain-_luIsM_B.mjs} +14 -16
- package/dist/{env-DNMJpeVF.mjs → env-CO5XAS9t.mjs} +23 -25
- package/dist/{env-helpers-B_ks681T.d.mts → env-helpers-z4stu8uc.d.mts} +1 -1
- package/dist/{env-types-BS8cZead.mjs → env-types-D51bnR-c.mjs} +3 -3
- package/dist/{env-validation-BxbtBbjh.mjs → env-validation-CeC2FL66.mjs} +4 -4
- package/dist/{fetch-error-C6qffTl2.mjs → fetch-error-Dj3crt0e.mjs} +3 -3
- package/dist/{gen-C0pV2gRQ.mjs → gen-Cf79J4aw.mjs} +42 -44
- package/dist/{github-cmd-CwtLD1yI.mjs → github-cmd-DnqxyOsb.mjs} +88 -90
- package/dist/{handler-B7rCOy21.d.mts → handler-imD0UVDT.d.mts} +4 -5
- package/dist/{headers-BNWymgnH.mjs → headers-BwvFGhkx.mjs} +3 -3
- package/dist/index.d.mts +3 -3
- package/dist/index.mjs +102 -83
- package/dist/{init-D58GxCtt.mjs → init-KirOzVDs.mjs} +132 -134
- package/dist/link-CUmiosyb.mjs +45 -0
- package/dist/{list-CbNNjXTm.mjs → list-3GEw7b6m.mjs} +10 -12
- package/dist/{login-CvxxF_9z.mjs → login-DJReaT_Q.mjs} +14 -15
- package/dist/{logs-BDZ9AuhM.mjs → logs-D-rQ56Lq.mjs} +9 -11
- package/dist/{magic-string.es-C1Fb0uxq.mjs → magic-string.es-ZQjdJFFn.mjs} +3 -3
- package/dist/{mcp-C8BjRt_z.mjs → mcp-D7yc0dXY.mjs} +2 -3
- package/dist/{node-B07cZs0d.mjs → node-yFFk626c.mjs} +6 -6
- package/dist/{package-json-Bg_GJdJB.mjs → package-json-B0NuUWGd.mjs} +1 -1
- package/dist/pages/client.d.mts +1 -1
- package/dist/pages/client.mjs +2 -1
- package/dist/pages/head-client.d.mts +1 -1
- package/dist/pages/head.d.mts +1 -1
- package/dist/pages/index.d.mts +2 -2
- package/dist/pages/index.mjs +5 -5
- package/dist/pages/islands-plugin.d.mts +1 -1
- package/dist/pages/islands-plugin.mjs +3 -3
- package/dist/pages/protocol.d.mts +2 -2
- package/dist/pages/protocol.mjs +5 -2
- package/dist/{plugin-inference-D04iL1mW.mjs → plugin-inference-CJxi_fWI.mjs} +3 -3
- package/dist/{prepare-DUo9q8cM.mjs → prepare-C_cVurhP.mjs} +15 -18
- package/dist/{preset-D0My64KQ.mjs → preset-CVvwCeIy.mjs} +4 -4
- package/dist/{project-cmd-Dd1gNRdd.mjs → project-cmd-DnU7u9QF.mjs} +13 -14
- package/dist/{project-paths-CCMrHYQm.mjs → project-paths-tpdR1mJR.mjs} +2 -2
- package/dist/{project-tsconfig-DMBV55K2.mjs → project-tsconfig-D9uSVVpA.mjs} +2 -2
- package/dist/{protocol-6UZCowS1.d.mts → protocol-6hTJ04T1.d.mts} +3 -3
- package/dist/{resolve-project-D4O1_fZz.mjs → resolve-project-D2HI3TrG.mjs} +2 -2
- package/dist/{rollback-DzmCCrFg.mjs → rollback-Yh7bCKob.mjs} +21 -23
- package/dist/{route-types-BpSJEW20.mjs → route-types-CfKfhbIg.mjs} +234 -3
- package/dist/{runner-BQyKUqAL.mjs → runner-h272wcPj.mjs} +4 -5
- package/dist/{runner-pg-EuhrFW3D.mjs → runner-pg-waxJOnBb.mjs} +1 -1
- package/dist/runtime/ai.mjs +2 -2
- package/dist/runtime/auth.d.mts +1 -1
- package/dist/runtime/better-auth-pg.d.mts +1 -1
- package/dist/runtime/better-auth-pg.mjs +3 -3
- package/dist/runtime/better-auth.d.mts +1 -1
- package/dist/runtime/better-auth.mjs +2 -2
- package/dist/runtime/client-react.d.mts +2 -2
- package/dist/runtime/client-react.mjs +1 -1
- package/dist/runtime/client-solid.d.mts +2 -2
- package/dist/runtime/client-solid.mjs +1 -1
- package/dist/runtime/client-svelte.d.mts +2 -2
- package/dist/runtime/client-svelte.mjs +1 -1
- package/dist/runtime/client-vue.d.mts +2 -2
- package/dist/runtime/client-vue.mjs +1 -1
- package/dist/runtime/client.d.mts +2 -2
- package/dist/runtime/client.mjs +1 -1
- package/dist/runtime/db-pg.d.mts +1 -1
- package/dist/runtime/env-helpers.d.mts +1 -1
- package/dist/runtime/env-public-client.d.mts +1 -1
- package/dist/runtime/env-public-client.mjs +2 -0
- package/dist/runtime/env-public.d.mts +3 -4
- package/dist/runtime/env-public.mjs +3 -1
- package/dist/runtime/env.mjs +1 -1
- package/dist/runtime/fetch-stream.d.mts +1 -1
- package/dist/runtime/fetch-stream.mjs +1 -1
- package/dist/runtime/fetch.d.mts +1 -1
- package/dist/runtime/fetch.mjs +1 -1
- package/dist/runtime/handler.d.mts +2 -2
- package/dist/runtime/handler.mjs +1 -1
- package/dist/runtime/isr.mjs +1 -1
- package/dist/runtime/live-server.mjs +2 -0
- package/dist/runtime/live.d.mts +2 -2
- package/dist/runtime/live.mjs +3 -1
- package/dist/runtime/migration-handler-pg.mjs +1 -1
- package/dist/runtime/migration-handler.mjs +1 -1
- package/dist/runtime/remote/index.mjs +11 -1
- package/dist/runtime/sandbox.d.mts +1 -4
- package/dist/runtime/sandbox.mjs +1 -1
- package/dist/runtime/validator.d.mts +1 -1
- package/dist/runtime/ws-server.d.mts +2 -2
- package/dist/runtime/ws-server.mjs +2 -0
- package/dist/runtime/ws.d.mts +3 -3
- package/dist/runtime/ws.mjs +2 -0
- package/dist/{scan-VCAM1oh3.mjs → scan-Dp_Gyzs3.mjs} +3 -3
- package/dist/{scan---8wfN58.mjs → scan-i7Yz54fv.mjs} +26 -8
- package/dist/{secret-CMLYWkE-.mjs → secret-u7FRvg8d.mjs} +22 -24
- package/dist/{skills-Dl3u05da.mjs → skills-DsdNDtX3.mjs} +6 -7
- package/dist/{subcommand-prompt-B8ng0FTS.mjs → subcommand-prompt-DtES-oP6.mjs} +34 -35
- package/dist/sveltekit.mjs +1 -1
- package/dist/validate-DT7nFMlf.mjs +504 -0
- package/dist/{yarn-pnp-WLW2IHUY.mjs → yarn-pnp-CW8LB6g_.mjs} +1 -1
- package/package.json +19 -19
- package/skills/void/docs/node_modules/void/node_modules/@clack/prompts/CHANGELOG.md +94 -0
- package/skills/void/docs/node_modules/void/node_modules/@clack/prompts/README.md +32 -11
- package/skills/void/docs/node_modules/void/node_modules/@cloudflare/sandbox/README.md +45 -0
- package/skills/void/docs/node_modules/void/node_modules/@electric-sql/pglite/README.md +5 -5
- package/skills/void/docs/node_modules/void/node_modules/@types/node/README.md +1 -1
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/@types/node/README.md +1 -1
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/markdown-exit/README.md +4 -1
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/tinyglobby/README.md +1 -1
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/AGENTS.md +1 -0
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/README.md +18 -6
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/build.md +1 -1
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/check.md +35 -0
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/create.md +70 -0
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/fmt.md +3 -1
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/index.md +11 -7
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/lint.md +3 -1
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/pack.md +1 -1
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/run.md +141 -26
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/staged.md +1 -1
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/config/test.md +1 -1
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/automatic-data-tracking.md +145 -0
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/cache.md +16 -28
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/check.md +16 -0
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/ci.md +15 -17
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/commit-hooks.md +9 -0
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/create.md +255 -2
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/docker.md +175 -0
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/env.md +70 -5
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/github-actions-cache.md +165 -0
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/ide-integration.md +2 -2
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/index.md +9 -3
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/install.md +63 -11
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/migrate-rules.md +347 -0
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/migrate.md +27 -3
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/monorepo.md +176 -0
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/pack.md +8 -0
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/run.md +36 -4
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/troubleshooting.md +11 -35
- package/skills/void/docs/node_modules/void/node_modules/@void/md/node_modules/vite-plus/docs/guide/upgrade.md +65 -13
- package/skills/void/docs/node_modules/void/node_modules/es-module-lexer/README.md +403 -390
- package/skills/void/docs/node_modules/void/node_modules/pg/README.md +2 -1
- package/skills/void/docs/node_modules/void/node_modules/tinyglobby/README.md +1 -1
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/AGENTS.md +1 -0
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/README.md +18 -6
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/build.md +1 -1
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/check.md +35 -0
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/create.md +70 -0
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/fmt.md +3 -1
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/index.md +11 -7
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/lint.md +3 -1
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/pack.md +1 -1
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/run.md +141 -26
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/staged.md +1 -1
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/config/test.md +1 -1
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/automatic-data-tracking.md +145 -0
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/cache.md +16 -28
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/check.md +16 -0
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/ci.md +15 -17
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/commit-hooks.md +9 -0
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/create.md +255 -2
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/docker.md +175 -0
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/env.md +70 -5
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/github-actions-cache.md +165 -0
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/ide-integration.md +2 -2
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/index.md +9 -3
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/install.md +63 -11
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/migrate-rules.md +347 -0
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/migrate.md +27 -3
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/monorepo.md +176 -0
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/pack.md +8 -0
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/run.md +36 -4
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/troubleshooting.md +11 -35
- package/skills/void/docs/node_modules/void/node_modules/vite-plus/docs/guide/upgrade.md +65 -13
- package/skills/void/docs/reference/cli.md +5 -1
- package/dist/agents-MhSzNMiC.mjs +0 -151
- package/dist/collect-9rO3JFNM.mjs +0 -55
- package/dist/config-hhMYPVRT.mjs +0 -21
- package/dist/dist-abzUneor.mjs +0 -1287
- package/dist/drizzle-DqstQTGq.mjs +0 -232
- package/dist/link-ZFmboqY3.mjs +0 -47
- package/dist/output-DeiS4oEX.mjs +0 -139
- package/dist/plan-aD3wRDqF.mjs +0 -271
- package/dist/project-CH9pdo16.mjs +0 -72
- package/dist/project-slug-rX3kTOfY.mjs +0 -10
- package/dist/validate-CNWm-PsL.mjs +0 -186
- /package/dist/{auth-migrations-BP-hMzYl.mjs → auth-migrations-BTZ-ATvQ.mjs} +0 -0
- /package/dist/{auth-Dz2CCn4T.d.mts → auth-qgMlYp7Z.d.mts} +0 -0
- /package/dist/{canonical-json-CEyQaVDa.mjs → canonical-json-DuDiiUsQ.mjs} +0 -0
- /package/dist/{cf-access-DKDsgwOU.mjs → cf-access-Bqw81xAf.mjs} +0 -0
- /package/dist/{defer-C-bdSM_b.mjs → defer-YsYDUoii.mjs} +0 -0
- /package/dist/{dotenv-lS94ymhM.mjs → dotenv-D_UbC_vc.mjs} +0 -0
- /package/dist/{env-raw-Dtj1UAoK.mjs → env-raw-CoS20LHP.mjs} +0 -0
- /package/dist/{fetch-error-B6RaJ-eZ.d.mts → fetch-error-Sp1R4mZv.d.mts} +0 -0
- /package/dist/{git-metadata-Ce0AtSZL.mjs → git-metadata-CBKaL0v5.mjs} +0 -0
- /package/dist/{head-eOUCWUNy.d.mts → head-nmvOgFjd.d.mts} +0 -0
- /package/dist/{log-BdD_Fpms.mjs → log-ChfPKsVd.mjs} +0 -0
- /package/dist/{pathe.M-eThtNZ-BrPhGF_K.mjs → pathe.M-eThtNZ-CQzLbt4c.mjs} +0 -0
- /package/dist/{pg-CempqvEJ.mjs → pg-J2HbZIkX.mjs} +0 -0
- /package/dist/{providers-BJIoduK9.d.mts → providers-BNKRacMr.d.mts} +0 -0
- /package/dist/{providers-BwPbdHdi.mjs → providers-CJlNS3kT.mjs} +0 -0
- /package/dist/{proxy-M3pxItg2.mjs → proxy-D-3_D-Gl.mjs} +0 -0
- /package/dist/{chunk-DJd-R1mw.mjs → rolldown-runtime-DJK8HYOj.mjs} +0 -0
- /package/dist/{standard-schema-Cy0lfeWv.d.mts → standard-schema-DJ0HW7QP.d.mts} +0 -0
- /package/dist/{types-BodZGegX.d.mts → types-lLjNE9Qp.d.mts} +0 -0
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
# GitHub Actions Cache
|
|
2
|
+
|
|
3
|
+
::: warning Experimental
|
|
4
|
+
Reusing Vite Task's cache across GitHub Actions runs is experimental. Test and measure it in your project before relying on it in CI.
|
|
5
|
+
:::
|
|
6
|
+
|
|
7
|
+
Vite Task stores task results in `node_modules/.vite/task-cache` at the workspace root. Restore that directory in later GitHub Actions runs so Vite Task can reuse previous task results.
|
|
8
|
+
|
|
9
|
+
GitHub Actions cache and Vite Task make separate decisions:
|
|
10
|
+
|
|
11
|
+
1. `actions/cache` restores and saves the cache directory based on the key in your workflow.
|
|
12
|
+
2. Vite Task uses the restored cache directory and replays only the tasks whose fingerprints still match.
|
|
13
|
+
|
|
14
|
+
## Before You Start
|
|
15
|
+
|
|
16
|
+
Use this workflow when all of these are true:
|
|
17
|
+
|
|
18
|
+
- The command runs through [`vp run`](/guide/run).
|
|
19
|
+
- An immediate second run reports a cache hit for the task.
|
|
20
|
+
- The task has stable input and output tracking for CI.
|
|
21
|
+
- The workflow installs dependencies before restoring `node_modules/.vite/task-cache`.
|
|
22
|
+
|
|
23
|
+
If the immediate second run misses, fix the task's tracking config before adding GitHub Actions cache. Check [When To Add Manual Config](/guide/automatic-data-tracking#when-to-add-manual-config) for common causes of unstable caching and fixes.
|
|
24
|
+
|
|
25
|
+
## Measure Before Caching Across Runs
|
|
26
|
+
|
|
27
|
+
You may not need to restore Vite Task cache across GitHub Actions runs when:
|
|
28
|
+
|
|
29
|
+
- The task is already fast enough. Restore and save steps add overhead, so short tasks can finish faster without this workflow.
|
|
30
|
+
- Cache transfer takes longer than rerunning the task. Vite Task can still save time inside one workflow run when the same task runs more than once, but across runs the transfer time is part of the cost.
|
|
31
|
+
|
|
32
|
+
Measure before you add a GitHub Actions cache for Vite Task. Compare workflow duration with and without the restore and save steps. Check both the GitHub cache step time and the `vp run` time.
|
|
33
|
+
|
|
34
|
+
## 1. Define Cacheable CI Tasks
|
|
35
|
+
|
|
36
|
+
Only commands run through `vp run` use Vite Task caching. A direct command such as `vp build` does not use the task cache. Define a task in `vite.config.ts` for each command you want to cache in CI:
|
|
37
|
+
|
|
38
|
+
```ts [vite.config.ts]
|
|
39
|
+
import { defineConfig } from 'vite-plus';
|
|
40
|
+
|
|
41
|
+
export default defineConfig({
|
|
42
|
+
run: {
|
|
43
|
+
tasks: {
|
|
44
|
+
build: 'vp build',
|
|
45
|
+
lint: 'vp lint',
|
|
46
|
+
},
|
|
47
|
+
},
|
|
48
|
+
});
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
This guide assumes each task already hits locally. If a task misses, fix its tracking config in `vite.config.ts` before adding the GitHub Actions cache steps. See [Automatic Data Tracking](/guide/automatic-data-tracking) and [`run.tasks`](/config/run#tasks).
|
|
52
|
+
|
|
53
|
+
Run each task twice:
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
vp run build
|
|
57
|
+
vp run build # should print "cache hit"
|
|
58
|
+
vp run lint
|
|
59
|
+
vp run lint # should print "cache hit"
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
## 2. Restore The Cache After Install
|
|
63
|
+
|
|
64
|
+
Restore `node_modules/.vite/task-cache` after `vp install`, because package installation can recreate or modify `node_modules`.
|
|
65
|
+
|
|
66
|
+
```yaml [.github/workflows/ci.yml]
|
|
67
|
+
name: CI
|
|
68
|
+
|
|
69
|
+
on:
|
|
70
|
+
pull_request:
|
|
71
|
+
push:
|
|
72
|
+
branches: [main]
|
|
73
|
+
|
|
74
|
+
permissions:
|
|
75
|
+
contents: read
|
|
76
|
+
|
|
77
|
+
jobs:
|
|
78
|
+
ci:
|
|
79
|
+
runs-on: ubuntu-latest
|
|
80
|
+
steps:
|
|
81
|
+
- uses: actions/checkout@v4
|
|
82
|
+
|
|
83
|
+
- uses: voidzero-dev/setup-vp@v1
|
|
84
|
+
with:
|
|
85
|
+
node-version: '24'
|
|
86
|
+
cache: true
|
|
87
|
+
|
|
88
|
+
- run: vp install
|
|
89
|
+
|
|
90
|
+
- name: Restore Vite Task cache
|
|
91
|
+
id: vite-task-cache
|
|
92
|
+
uses: actions/cache/restore@v6
|
|
93
|
+
with:
|
|
94
|
+
path: node_modules/.vite/task-cache
|
|
95
|
+
key: vite-task-${{ runner.os }}-${{ runner.arch }}-${{ github.run_id }}-${{ github.run_attempt }}
|
|
96
|
+
restore-keys: |
|
|
97
|
+
vite-task-${{ runner.os }}-${{ runner.arch }}-
|
|
98
|
+
|
|
99
|
+
- run: vp run lint
|
|
100
|
+
- run: vp run build
|
|
101
|
+
|
|
102
|
+
- name: Save Vite Task cache
|
|
103
|
+
if: success()
|
|
104
|
+
uses: actions/cache/save@v6
|
|
105
|
+
with:
|
|
106
|
+
path: node_modules/.vite/task-cache
|
|
107
|
+
key: ${{ steps.vite-task-cache.outputs.cache-primary-key }}
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
The primary key includes `github.run_id` and `github.run_attempt` so each successful run can save a new immutable cache entry. The restore prefix lets GitHub restore the newest cache for the same operating system and architecture.
|
|
111
|
+
|
|
112
|
+
Leave task inputs, including source files and lockfiles, out of the GitHub Actions key. Vite Task fingerprints them. If they change the Actions key, GitHub can skip useful restores before Vite Task decides which tasks still hit.
|
|
113
|
+
|
|
114
|
+
For monorepos, restore the task cache from the workspace root. Then run the same `vp run` commands you use locally, such as `vp run -t @my/app#build`. Vite Task can reuse results for the requested package and the packages it depends on.
|
|
115
|
+
|
|
116
|
+
## 3. Verify In The Logs
|
|
117
|
+
|
|
118
|
+
On the first run, the restore step should say that no cache was found, and the save step should create one. Pull requests from forks may be restore-only because GitHub can give the cache token read-only access. In that case, the save step warns and exits successfully without writing a cache entry.
|
|
119
|
+
|
|
120
|
+
On a later run, look for both layers:
|
|
121
|
+
|
|
122
|
+
```text
|
|
123
|
+
Cache restored from key: vite-task-Linux-X64-...
|
|
124
|
+
$ vp build ◉ cache hit, replaying
|
|
125
|
+
vp run: cache hit, 1.10s saved.
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
If GitHub restores a cache but Vite Task prints a cache miss, the workflow restored the cache directory, but the task fingerprint changed.
|
|
129
|
+
|
|
130
|
+
## Keep Task Tracking Stable
|
|
131
|
+
|
|
132
|
+
If GitHub restores a cache but `vp run` prints a cache miss, fix the task fingerprint before changing the Actions cache key. See [Automatic Data Tracking](/guide/automatic-data-tracking) and [`run.tasks`](/config/run#tasks).
|
|
133
|
+
|
|
134
|
+
## Choose A Cache Key
|
|
135
|
+
|
|
136
|
+
Use a rolling primary key plus a restore prefix:
|
|
137
|
+
|
|
138
|
+
```yaml [.github/workflows/ci.yml]
|
|
139
|
+
key: vite-task-${{ runner.os }}-${{ runner.arch }}-${{ github.run_id }}-${{ github.run_attempt }}
|
|
140
|
+
restore-keys: |
|
|
141
|
+
vite-task-${{ runner.os }}-${{ runner.arch }}-
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
The primary key is unique for each run because it contains `github.run_id` and `github.run_attempt`. GitHub then searches the restore prefix and restores the newest matching cache.
|
|
145
|
+
|
|
146
|
+
Include:
|
|
147
|
+
|
|
148
|
+
- `runner.os` and `runner.arch`, because outputs and native tools can be platform-specific.
|
|
149
|
+
- A per-run value such as `github.run_id` and `github.run_attempt`, because GitHub cache entries are immutable.
|
|
150
|
+
|
|
151
|
+
If a dependency file affects a task result, track it in the task fingerprint rather than the GitHub Actions key.
|
|
152
|
+
|
|
153
|
+
## Manage Cache Eviction And Scope
|
|
154
|
+
|
|
155
|
+
GitHub evicts caches based on its cache retention and repository storage rules. Cache scope is also branch-aware: workflow runs can restore caches from the current branch and the default branch, while pull request merge-ref caches have limited scope.
|
|
156
|
+
|
|
157
|
+
Vite Task can clear the whole task cache, but it does not currently evict individual task entries by age or size. As new task entries and output archives are saved, `node_modules/.vite/task-cache` can keep growing.
|
|
158
|
+
|
|
159
|
+
Manage size at the GitHub Actions cache layer:
|
|
160
|
+
|
|
161
|
+
- Keep the cached `path` limited to the Vite Task cache directory.
|
|
162
|
+
- Keep the restore prefix scoped to compatible runners, such as the same OS and architecture.
|
|
163
|
+
- Delete stale GitHub Actions cache entries, save caches from fewer workflows, or adjust the repository cache limit if large caches cause frequent evictions.
|
|
164
|
+
|
|
165
|
+
See [GitHub's cache reference](https://docs.github.com/en/actions/reference/workflows-and-actions/dependency-caching) for the current eviction and scope rules.
|
|
@@ -71,7 +71,7 @@ You can also manually set up the Zed config:
|
|
|
71
71
|
"oxfmt": {
|
|
72
72
|
"initialization_options": {
|
|
73
73
|
"settings": {
|
|
74
|
-
"configPath": "./vite.config.ts",
|
|
74
|
+
"fmt.configPath": "./vite.config.ts",
|
|
75
75
|
"run": "onSave"
|
|
76
76
|
}
|
|
77
77
|
}
|
|
@@ -98,4 +98,4 @@ You can also manually set up the Zed config:
|
|
|
98
98
|
}
|
|
99
99
|
```
|
|
100
100
|
|
|
101
|
-
Setting `oxfmt.configPath` to `./vite.config.ts` keeps editor format-on-save aligned with the `fmt` block in your Vite+ config. The full generated config covers additional languages (CSS, HTML, JSON, Markdown, etc.) — run `vp create` or `vp migrate` to get the complete file written automatically.
|
|
101
|
+
Setting `oxfmt.fmt.configPath` to `./vite.config.ts` keeps editor format-on-save aligned with the `fmt` block in your Vite+ config. The full generated config covers additional languages (CSS, HTML, JSON, Markdown, etc.) — run `vp create` or `vp migrate` to get the complete file written automatically.
|
|
@@ -4,6 +4,10 @@ Vite+ is the unified toolchain and entry point for web development. It manages y
|
|
|
4
4
|
|
|
5
5
|
Vite+ ships in two parts: `vp`, the global command-line tool, and `vite-plus`, the local package installed in each project. If you already have a Vite project, use [`vp migrate`](/guide/migrate) to migrate it to Vite+, or paste our [migration prompt](/guide/migrate#migration-prompt) into your coding agent.
|
|
6
6
|
|
|
7
|
+
Building with an AI assistant? Copy a ready-made setup prompt:
|
|
8
|
+
|
|
9
|
+
<CopyPrompt />
|
|
10
|
+
|
|
7
11
|
## Install `vp`
|
|
8
12
|
|
|
9
13
|
### macOS / Linux
|
|
@@ -100,10 +104,11 @@ Vite+ can handle the entire local frontend development cycle from starting a pro
|
|
|
100
104
|
### Execute
|
|
101
105
|
|
|
102
106
|
- [`vp run`](/guide/run) runs tasks across workspaces with caching.
|
|
103
|
-
- [`vp cache clean`](/guide/cache) clears task cache entries.
|
|
104
|
-
- [`vpx`](/guide/vpx) downloads and runs binaries globally.
|
|
105
107
|
- [`vp exec`](/guide/vpx) runs local project binaries.
|
|
108
|
+
- [`vp node`](/guide/env) runs Node.js scripts with the resolved Vite+ environment.
|
|
106
109
|
- [`vp dlx`](/guide/vpx) downloads and runs package binaries without adding them as dependencies.
|
|
110
|
+
- [`vp cache clean`](/guide/cache) clears task cache entries.
|
|
111
|
+
- [`vpx`](/guide/vpx) downloads and runs binaries globally.
|
|
107
112
|
|
|
108
113
|
### Build
|
|
109
114
|
|
|
@@ -113,7 +118,8 @@ Vite+ can handle the entire local frontend development cycle from starting a pro
|
|
|
113
118
|
|
|
114
119
|
### Manage Dependencies
|
|
115
120
|
|
|
116
|
-
- [`vp add`](/guide/install), [`vp remove`](/guide/install), [`vp update`](/guide/install), [`vp dedupe`](/guide/install), [`vp outdated`](/guide/install), [`vp why`](/guide/install), and [`vp info`](/guide/install) wrap package-manager workflows.
|
|
121
|
+
- [`vp add`](/guide/install), [`vp remove`](/guide/install), [`vp update`](/guide/install), [`vp dedupe`](/guide/install), [`vp outdated`](/guide/install), [`vp list`](/guide/install), [`vp why`](/guide/install), and [`vp info`](/guide/install) wrap package-manager workflows.
|
|
122
|
+
- [`vp link`](/guide/install), [`vp unlink`](/guide/install), and [`vp rebuild`](/guide/install) cover local package links and native module rebuilds.
|
|
117
123
|
- [`vp pm <command>`](/guide/install) calls other package manager commands directly.
|
|
118
124
|
|
|
119
125
|
### Maintain
|
|
@@ -9,16 +9,37 @@ Use Vite+ to manage dependencies across pnpm, npm, Yarn, and Bun. Instead of swi
|
|
|
9
9
|
Vite+ detects the package manager from the workspace root in this order:
|
|
10
10
|
|
|
11
11
|
1. `packageManager` in `package.json`
|
|
12
|
-
2. `
|
|
13
|
-
3. `pnpm-
|
|
14
|
-
4. `
|
|
15
|
-
5. `
|
|
16
|
-
6. `
|
|
17
|
-
7.
|
|
18
|
-
8. `
|
|
19
|
-
9. `
|
|
12
|
+
2. `devEngines.packageManager` in `package.json`
|
|
13
|
+
3. `pnpm-workspace.yaml`
|
|
14
|
+
4. `pnpm-lock.yaml`
|
|
15
|
+
5. `yarn.lock` or `.yarnrc.yml`
|
|
16
|
+
6. `package-lock.json`
|
|
17
|
+
7. `bun.lock` or `bun.lockb`
|
|
18
|
+
8. `.pnpmfile.cjs` or `pnpmfile.cjs`
|
|
19
|
+
9. `bunfig.toml`
|
|
20
|
+
10. `yarn.config.cjs`
|
|
21
|
+
|
|
22
|
+
If none of those files are present, `vp` falls back to `pnpm` by default. Vite+ automatically downloads the matching package manager and uses it for the command you ran. When detection comes from lockfiles or config files, the resolved version is written to `devEngines.packageManager` so future runs are deterministic; projects that already declare `packageManager` or `devEngines.packageManager` are left as-is.
|
|
23
|
+
|
|
24
|
+
The [`devEngines.packageManager`](https://docs.npmjs.com/cli/v11/configuring-npm/package-json#devengines) field accepts a single object or an array of objects, and its `version` may be a semver range:
|
|
25
|
+
|
|
26
|
+
```json
|
|
27
|
+
{
|
|
28
|
+
"devEngines": {
|
|
29
|
+
"packageManager": {
|
|
30
|
+
"name": "pnpm",
|
|
31
|
+
"version": "^11.0.0",
|
|
32
|
+
"onFail": "download"
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
A range resolves to an already-downloaded satisfying version when possible, otherwise to the latest satisfying version from the npm registry. The range itself stays the source of truth; Vite+ never freezes it into an exact `packageManager` pin. When both `packageManager` and `devEngines.packageManager` are declared, the `packageManager` field drives selection and Vite+ warns when it does not satisfy the devEngines constraint (`vp env doctor` shows details).
|
|
20
39
|
|
|
21
|
-
|
|
40
|
+
Vite+ currently downloads the declared package manager (the `onFail: "download"` behavior); the other `onFail` values are accepted but not yet differentiated.
|
|
41
|
+
|
|
42
|
+
The explicit `packageManager` field (or the `devEngines.packageManager` declaration) also affects matching package-manager shims. If a project has `packageManager: "npm@10.9.4"`, `npm` and `npx` use npm 10.9.4. Other generated alias pairs behave the same way: `pnpm`/`pnpx`, `yarn`/`yarnpkg`, and `bun`/`bunx`. Mismatched tools are not translated; `npm` in a `pnpm` project still resolves as npm.
|
|
22
43
|
|
|
23
44
|
## Usage
|
|
24
45
|
|
|
@@ -46,6 +67,15 @@ Use the `-g` flag for installing, updating or removing globally installed packag
|
|
|
46
67
|
- `vp uninstall -g <pkg>` removes a global package
|
|
47
68
|
- `vp update -g [pkg]` updates one global package or all of them
|
|
48
69
|
- `vp list -g [pkg]` lists global packages
|
|
70
|
+
- `vp outdated -g [pkg]` prints outdated packages
|
|
71
|
+
|
|
72
|
+
::: warning
|
|
73
|
+
These commands do **NOT** interact with the underlying package manager's global installation directory.
|
|
74
|
+
|
|
75
|
+
Instead, Vite+ manages its own global packages under `~/.vite-plus/packages`, allowing them to remain available across different Node.js versions.
|
|
76
|
+
|
|
77
|
+
As a result, commands such as `vp link` do not affect Vite+'s global packages and will not appear in `vp list -g`.
|
|
78
|
+
:::
|
|
49
79
|
|
|
50
80
|
## Managing Dependencies
|
|
51
81
|
|
|
@@ -88,6 +118,7 @@ Use these commands when you want package-manager-managed tools available outside
|
|
|
88
118
|
- `vp uninstall -g typescript`
|
|
89
119
|
- `vp update -g`
|
|
90
120
|
- `vp list -g`
|
|
121
|
+
- `vp outdated -g`
|
|
91
122
|
|
|
92
123
|
#### Add and Remove
|
|
93
124
|
|
|
@@ -121,15 +152,19 @@ Use these when you need to understand the current state of dependencies.
|
|
|
121
152
|
Use `vp rebuild` when native modules need to be recompiled, for example after switching Node.js versions or when a C/C++ addon fails to load.
|
|
122
153
|
|
|
123
154
|
- `vp rebuild` rebuilds all native modules
|
|
155
|
+
- `vp rebuild <package...>` rebuilds the listed packages only
|
|
124
156
|
- `vp rebuild -- <args>` passes extra arguments to the underlying package manager
|
|
125
157
|
|
|
126
158
|
```bash
|
|
127
159
|
vp rebuild
|
|
160
|
+
vp rebuild better-sqlite3 sharp
|
|
128
161
|
vp rebuild -- --update-binary
|
|
129
162
|
```
|
|
130
163
|
|
|
131
164
|
`vp rebuild` is a shorthand for `vp pm rebuild`.
|
|
132
165
|
|
|
166
|
+
With pnpm v10+, bare `vp rebuild` only rebuilds packages whose build scripts are listed in `onlyBuiltDependencies` (or approved via `pnpm approve-builds`); name the package explicitly to force a rebuild that bypasses the approval gate.
|
|
167
|
+
|
|
133
168
|
#### Advanced
|
|
134
169
|
|
|
135
170
|
Use these when you need lower-level package-manager behavior.
|
|
@@ -142,6 +177,23 @@ Examples:
|
|
|
142
177
|
|
|
143
178
|
```bash
|
|
144
179
|
vp pm config get registry
|
|
145
|
-
vp pm cache clean --force
|
|
146
|
-
vp pm
|
|
180
|
+
vp pm cache clean -- --force
|
|
181
|
+
vp pm audit --json
|
|
147
182
|
```
|
|
183
|
+
|
|
184
|
+
#### Staged publishing
|
|
185
|
+
|
|
186
|
+
`vp pm stage` exposes [npm's staged publishing](https://docs.npmjs.com/staged-publishing) workflow: a build is uploaded to a staging area (no 2FA, CI-friendly), then a maintainer approves or rejects it from a trusted device (2FA). It adapts to the detected package manager.
|
|
187
|
+
|
|
188
|
+
```bash
|
|
189
|
+
vp pm stage publish # upload the package to staging (no 2FA)
|
|
190
|
+
vp pm stage list # list staged versions
|
|
191
|
+
vp pm stage view <stage-id> # inspect a staged version
|
|
192
|
+
vp pm stage download <stage-id> # download the staged tarball
|
|
193
|
+
vp pm stage approve <stage-id> # promote to the live registry (2FA)
|
|
194
|
+
vp pm stage reject <stage-id> # discard a staged version (2FA)
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
- pnpm (`pnpm stage`, requires pnpm ≥ 11.3) and npm (`npm stage`, requires npm ≥ 11.15 and Node ≥ 22.14) pass through directly.
|
|
198
|
+
- yarn (Berry) uses its npm plugin (`yarn npm publish --staged`, `yarn npm stage …`); `view`/`download` fall back to npm.
|
|
199
|
+
- yarn Classic and bun have no staged-publishing support and fall back to `npm stage`.
|