@visulima/vis 7.1.0-next.6 β†’ 7.1.0-next.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.
Files changed (158) hide show
  1. package/CHANGELOG.md +59 -0
  2. package/README.md +1 -1
  3. package/dist/bin.js +1 -1
  4. package/dist/binx.js +1 -1
  5. package/dist/config/index.d.ts +227 -12
  6. package/dist/packem_chunks/CONFIG_FILES.js +1 -1
  7. package/dist/packem_chunks/bloom-sync.js +1 -1
  8. package/dist/packem_chunks/catalog.js +1 -1
  9. package/dist/packem_chunks/cli-exec.js +1 -1
  10. package/dist/packem_chunks/cli-main.js +57 -57
  11. package/dist/packem_chunks/detect.js +4 -4
  12. package/dist/packem_chunks/dispatch.js +1 -1
  13. package/dist/packem_chunks/fix.js +1 -1
  14. package/dist/packem_chunks/handler.js +1 -1
  15. package/dist/packem_chunks/handler10.js +1 -1
  16. package/dist/packem_chunks/handler11.js +1 -1
  17. package/dist/packem_chunks/handler12.js +1 -1
  18. package/dist/packem_chunks/handler13.js +1 -1
  19. package/dist/packem_chunks/handler14.js +1 -1
  20. package/dist/packem_chunks/handler15.js +1 -1
  21. package/dist/packem_chunks/handler16.js +1 -1
  22. package/dist/packem_chunks/handler17.js +1 -1
  23. package/dist/packem_chunks/handler18.js +1 -1
  24. package/dist/packem_chunks/handler19.js +1 -1
  25. package/dist/packem_chunks/handler2.js +1 -1
  26. package/dist/packem_chunks/handler20.js +1 -1
  27. package/dist/packem_chunks/handler21.js +1 -1
  28. package/dist/packem_chunks/handler22.js +1 -1
  29. package/dist/packem_chunks/handler23.js +1 -1
  30. package/dist/packem_chunks/handler24.js +1 -1
  31. package/dist/packem_chunks/handler25.js +1 -1
  32. package/dist/packem_chunks/handler26.js +1 -1
  33. package/dist/packem_chunks/handler27.js +1 -1
  34. package/dist/packem_chunks/handler28.js +1 -1
  35. package/dist/packem_chunks/handler29.js +1 -1
  36. package/dist/packem_chunks/handler3.js +2 -2
  37. package/dist/packem_chunks/handler30.js +1 -1
  38. package/dist/packem_chunks/handler4.js +1 -1
  39. package/dist/packem_chunks/handler5.js +1 -1
  40. package/dist/packem_chunks/handler50.js +1 -1
  41. package/dist/packem_chunks/handler51.js +1 -1
  42. package/dist/packem_chunks/handler52.js +1 -1
  43. package/dist/packem_chunks/handler53.js +1 -1
  44. package/dist/packem_chunks/handler54.js +1 -1
  45. package/dist/packem_chunks/handler55.js +1 -1
  46. package/dist/packem_chunks/handler58.js +1 -1
  47. package/dist/packem_chunks/handler59.js +1 -1
  48. package/dist/packem_chunks/handler6.js +1 -1
  49. package/dist/packem_chunks/handler60.js +1 -1
  50. package/dist/packem_chunks/handler61.js +22 -3
  51. package/dist/packem_chunks/handler62.js +2 -22
  52. package/dist/packem_chunks/handler63.js +6 -2
  53. package/dist/packem_chunks/handler64.js +8 -61
  54. package/dist/packem_chunks/handler65.js +2 -6
  55. package/dist/packem_chunks/handler66.js +12 -8
  56. package/dist/packem_chunks/handler67.js +5 -2
  57. package/dist/packem_chunks/handler68.js +25 -12
  58. package/dist/packem_chunks/handler69.js +50 -25
  59. package/dist/packem_chunks/handler7.js +1 -1
  60. package/dist/packem_chunks/handler70.js +153 -50
  61. package/dist/packem_chunks/handler71.js +1 -1
  62. package/dist/packem_chunks/handler72.js +1 -1
  63. package/dist/packem_chunks/handler73.js +1 -1
  64. package/dist/packem_chunks/handler74.js +1 -1
  65. package/dist/packem_chunks/handler75.js +1 -1
  66. package/dist/packem_chunks/handler76.js +1 -1
  67. package/dist/packem_chunks/handler77.js +1 -1
  68. package/dist/packem_chunks/handler78.js +1 -1
  69. package/dist/packem_chunks/handler79.js +64 -64
  70. package/dist/packem_chunks/handler8.js +1 -1
  71. package/dist/packem_chunks/handler9.js +1 -1
  72. package/dist/packem_chunks/heal-accept.js +1 -1
  73. package/dist/packem_chunks/heal.js +1 -1
  74. package/dist/packem_chunks/help-command.js +1 -1
  75. package/dist/packem_chunks/index7.js +1 -1
  76. package/dist/packem_chunks/keys-refresh.js +1 -1
  77. package/dist/packem_chunks/lean.js +1 -1
  78. package/dist/packem_chunks/list.js +1 -1
  79. package/dist/packem_chunks/loader.js +1 -1
  80. package/dist/packem_chunks/prune.js +1 -1
  81. package/dist/packem_chunks/status.js +1 -1
  82. package/dist/packem_chunks/sync.js +1 -1
  83. package/dist/packem_chunks/sync2.js +1 -1
  84. package/dist/packem_chunks/tripwire.js +1 -1
  85. package/dist/packem_chunks/ts-loader.js +2 -2
  86. package/dist/packem_chunks/verify-lockfile.js +1 -1
  87. package/dist/packem_chunks/workflow-templates.js +29 -32
  88. package/dist/packem_shared/{advisories-BnFPhsl1.js β†’ advisories-CyXUdibZ.js} +1 -1
  89. package/dist/packem_shared/{affected-selection-Bd03KJU3.js β†’ affected-selection-CJnDzyIK.js} +1 -1
  90. package/dist/packem_shared/affected-shas-CJLirD2O.js +1 -0
  91. package/dist/packem_shared/{ai-analysis-GjV2rF4U.js β†’ ai-analysis-DHlzow2O.js} +1 -1
  92. package/dist/packem_shared/{ai-cache-DFKUyj11.js β†’ ai-cache-D-BSLcuJ.js} +1 -1
  93. package/dist/packem_shared/{ai-fix-DpBEXHZT.js β†’ ai-fix-CyExJC_c.js} +1 -1
  94. package/dist/packem_shared/{augment-BSeqaai8.js β†’ augment-Ub6PCwbh.js} +1 -1
  95. package/dist/packem_shared/{bin-D1zq7wxi.js β†’ bin-BaReRSyo.js} +1 -1
  96. package/dist/packem_shared/{build-scripts-mKGcgTzp.js β†’ build-scripts-BeJkep8z.js} +1 -1
  97. package/dist/packem_shared/ci-commands-4W9d2six.js +1 -0
  98. package/dist/packem_shared/{command-runtime-DG49t2MT.js β†’ command-runtime-DdnpiUmN.js} +1 -1
  99. package/dist/packem_shared/{dependency-scan-BGKZYS_i.js β†’ dependency-scan-CyByCwef.js} +1 -1
  100. package/dist/packem_shared/{detect-CaA92iu_.js β†’ detect-xqoTANJb.js} +1 -1
  101. package/dist/packem_shared/{docker-Cs174Imq.js β†’ docker-CJXAt5Au.js} +1 -1
  102. package/dist/packem_shared/{ecosystem-gate-DcpvfgEi.js β†’ ecosystem-gate-DEnubRcS.js} +1 -1
  103. package/dist/packem_shared/{env-sb3SOT-b.js β†’ env-NauRSSEC.js} +1 -1
  104. package/dist/packem_shared/{env-consistency-nSuzisQe.js β†’ env-consistency-Cl1Rg65z.js} +1 -1
  105. package/dist/packem_shared/{failure-log-AtaeZOrx.js β†’ failure-log-DwroazKs.js} +1 -1
  106. package/dist/packem_shared/glob-Cyk1H9ZL-BtN6Zzwg.js +1 -0
  107. package/dist/packem_shared/{index-CclzWrJ5.js β†’ index-BCEhCrLl.js} +1 -1
  108. package/dist/packem_shared/{index-C_7lOmB0.js β†’ index-OmE1O0Ys.js} +1 -1
  109. package/dist/packem_shared/{index-0dnGN3GP.js β†’ index-zq6Ehql6.js} +1 -1
  110. package/dist/packem_shared/{isAccessibleSync-DYKTrrvc-CBsMZhj-.js β†’ isAccessibleSync-DYKTrrvc-CKahNmLy.js} +1 -1
  111. package/dist/packem_shared/{lifecycle-BzenugED.js β†’ lifecycle-Cn1mSP5f.js} +1 -1
  112. package/dist/packem_shared/{lockfile-DEWjBrlY.js β†’ lockfile-Cx2Ny3um.js} +1 -1
  113. package/dist/packem_shared/{manifests-DPwVdkqB.js β†’ manifests-BEGTH1ZG.js} +1 -1
  114. package/dist/packem_shared/{min-release-age-BH4JKSXA.js β†’ min-release-age-DLAERxRt.js} +1 -1
  115. package/dist/packem_shared/{missing-package-json-ByjsDBbk.js β†’ missing-package-json-w74qGfyh.js} +1 -1
  116. package/dist/packem_shared/{multi-eco-lockfiles-Bz9ViPBV.js β†’ multi-eco-lockfiles-SATPXx6-.js} +1 -1
  117. package/dist/packem_shared/{native-config-sync-DI7_xs-Q.js β†’ native-config-sync-DDFn6Zsf.js} +1 -1
  118. package/dist/packem_shared/{npmrc-CIvOb61L.js β†’ npmrc-DONprxrc.js} +1 -1
  119. package/dist/packem_shared/{osv-DaMZpVWl.js β†’ osv-dvIA_vX3.js} +1 -1
  120. package/dist/packem_shared/{package-version-VdULnxr1.js β†’ package-version-BOK3IncQ.js} +2 -2
  121. package/dist/packem_shared/{packument-zeKEhTaX.js β†’ packument-B678kHJO.js} +1 -1
  122. package/dist/packem_shared/{pm-runner-BXRi4ZM9.js β†’ pm-runner-CYsiSHYa.js} +1 -1
  123. package/dist/packem_shared/{project-name-filter-BklluD5Y.js β†’ project-name-filter-CBEoY08a.js} +1 -1
  124. package/dist/packem_shared/{provenance-CwyZDw8A.js β†’ provenance-D4ioWGBq.js} +1 -1
  125. package/dist/packem_shared/reachable-DX8FPErP.js +1 -0
  126. package/dist/packem_shared/{registry-TXpTtpgS.js β†’ registry-ClmannRw.js} +2 -2
  127. package/dist/packem_shared/{registry-keys-B4CNE38T.js β†’ registry-keys-CF45rOur.js} +1 -1
  128. package/dist/packem_shared/{removeSync-g1D5kONg-jOsRSIIv.js β†’ removeSync-g1D5kONg-DcG75b0G.js} +1 -1
  129. package/dist/packem_shared/{renderToString-DR0zDUjh-CdBv7J9a.js β†’ renderToString-DR0zDUjh-CBDmAXxb.js} +1 -1
  130. package/dist/packem_shared/{resolve-explicit-Cg3eqSqr.js β†’ resolve-explicit-C5-y-xEU.js} +1 -1
  131. package/dist/packem_shared/{resolve-runtime-D8rxuo3J.js β†’ resolve-runtime-DBDozrmt.js} +1 -1
  132. package/dist/packem_shared/{run-file-D1mlOnd8.js β†’ run-file-BKXvoVj2.js} +1 -1
  133. package/dist/packem_shared/{run-summary-utils-CZ2pIIOZ.js β†’ run-summary-utils-75paIrLB.js} +1 -1
  134. package/dist/packem_shared/{runtime-check-By5NHR00.js β†’ runtime-check-Yl8-Awkf.js} +1 -1
  135. package/dist/packem_shared/{s1ngularity-CXTWGOvX.js β†’ s1ngularity-B2bqwE0C.js} +1 -1
  136. package/dist/packem_shared/{scaffold-files-CC1M9Gje.js β†’ scaffold-files-UiCBBCT5.js} +1 -1
  137. package/dist/packem_shared/{scan-progress-BaCJp5nr.js β†’ scan-progress-Dws7Gif1.js} +1 -1
  138. package/dist/packem_shared/{selectors-DdvjAetv.js β†’ selectors-DZ4HDnlD.js} +1 -1
  139. package/dist/packem_shared/{signatures-Bm-ySKmD.js β†’ signatures-DNqgsRp7.js} +1 -1
  140. package/dist/packem_shared/{spinner-D8Eugb6Y.js β†’ spinner-BQ9mLz8X.js} +1 -1
  141. package/dist/packem_shared/{table-Dc3wOjzc.js β†’ table-D1CpySxU.js} +1 -1
  142. package/dist/packem_shared/{tabs-Ch5hj2ow.js β†’ tabs-BYtpIN5b.js} +1 -1
  143. package/dist/packem_shared/{target-options-rIthWS4M.js β†’ target-options-CsevVc7U.js} +1 -1
  144. package/dist/packem_shared/{task-env-Cl4jNMCR.js β†’ task-env-BftNOR00.js} +1 -1
  145. package/dist/packem_shared/{toolchain-DQIOCPht.js β†’ toolchain-BvluBdrw.js} +1 -1
  146. package/dist/packem_shared/{typosquats-Dw02Q55Q.js β†’ typosquats-XrArH9TO.js} +1 -1
  147. package/dist/packem_shared/{use-measured-height-wtekNTLa.js β†’ use-measured-height-hHis1NaB.js} +1 -1
  148. package/dist/packem_shared/{verify-3WE9U_Bv.js β†’ verify-Dic2G0nQ.js} +1 -1
  149. package/dist/packem_shared/{vis-update-app-it6zkxW1.js β†’ vis-update-app-BNnbDZ--.js} +1 -1
  150. package/dist/packem_shared/{vis-user-error-6sSghaC9.js β†’ vis-user-error-DhgW3DzD.js} +2 -2
  151. package/dist/packem_shared/{watch-C-9-PD2m.js β†’ watch-BLHtUgfb.js} +1 -1
  152. package/dist/packem_shared/{watch-loop-q7f9ukDX.js β†’ watch-loop-Dh4GHUVS.js} +7 -7
  153. package/dist/runtime/preload.js +1 -1
  154. package/index.js +54 -54
  155. package/package.json +11 -10
  156. package/schemas/vis-config.schema.json +1419 -80
  157. package/dist/packem_shared/affected-shas-CycHU3nr.js +0 -1
  158. package/dist/packem_shared/glob-Cyk1H9ZL-QtJl508G.js +0 -1
package/CHANGELOG.md CHANGED
@@ -1,3 +1,62 @@
1
+ ## @visulima/vis [7.1.0-next.7](https://github.com/visulima/vis/compare/@visulima/vis@7.1.0-next.6...@visulima/vis@7.1.0-next.7) (2026-11-22)
2
+
3
+ ### Features
4
+
5
+ * **vis:** detect the CI provider for `vis sync ci-workflow` ([10a08e1](https://github.com/visulima/vis/commit/10a08e1f23c5344a3e41e1031d0a29e4699e7587))
6
+ * **vis:** format with a bundled oxfmt and a config fallback chain ([#162](https://github.com/visulima/vis/issues/162)) ([17e607c](https://github.com/visulima/vis/commit/17e607cf49fe13abad53c092ba95d836341d70d8))
7
+ * **vis:** generate CI workflows that run targets as parallel steps ([88cdbea](https://github.com/visulima/vis/commit/88cdbea0303c11246e5cf948a0880fd7fee44245))
8
+ * **vis:** harden generated CI workflows and support non-JS toolchains ([4a486f6](https://github.com/visulima/vis/commit/4a486f664ed9dbe1eb74e310f25796dc049f2a5f))
9
+ * **vis:** keep the fmt config in the vis cache when it has no globs ([#165](https://github.com/visulima/vis/issues/165)) ([3a4d727](https://github.com/visulima/vis/commit/3a4d727afcfaa3e33e476cfe60bc0f6e18b0c8bd))
10
+ * **vis:** let a workflow target carry a project query ([1e55891](https://github.com/visulima/vis/commit/1e558915a6133787239a9f020cf376cb7afb89ca))
11
+ * **vis:** run the generated GitHub workflow in a merge queue ([fa53fe3](https://github.com/visulima/vis/commit/fa53fe37e5e0f30fec375bfccbca69d1b765cfda))
12
+ * **vis:** typed extension points for the generated CI workflow ([2661053](https://github.com/visulima/vis/commit/26610534019a171a112f60ac40f6dc6fbd0d9f47))
13
+
14
+ ### Bug Fixes
15
+
16
+ * **vis:** address review feedback on the ci-workflow generator ([3d17402](https://github.com/visulima/vis/commit/3d174020f7ea4261970442e8b7d0e4d8790d4a9d))
17
+ * **vis:** check the workflow drift against the providers it was generated for ([dec7e60](https://github.com/visulima/vis/commit/dec7e60bb0ffd2508b5008b6bdee43a8547f1365))
18
+ * **vis:** drop `--skip-toolchain` from the `vis ci` parallel-step example ([f2786f8](https://github.com/visulima/vis/commit/f2786f8184ad27fa9fd871907b18853841a95301))
19
+ * **vis:** give each non-PR CI run its own concurrency group ([f2a1995](https://github.com/visulima/vis/commit/f2a19958e73aad2d3fbbb6f1c02aed0f3e84f945))
20
+ * **vis:** install the aube executable in generated CI workflows ([ed58e59](https://github.com/visulima/vis/commit/ed58e592f9c137ae8d7afc13484bd50e83653f77))
21
+ * **vis:** keep a dependency's services and drop finalizers from `vis run --deps-only` ([4fbec78](https://github.com/visulima/vis/commit/4fbec78eb47de0f57342fe2bc98825b159e0e91c))
22
+ * **vis:** let the generated GitLab jobs use the including pipeline's stage, and refuse values GitLab rejects ([5cad57e](https://github.com/visulima/vis/commit/5cad57e6d283efbd16df05a1b2385b68e14280d8))
23
+ * **vis:** pin .NET from a project's global.json in the generated GitHub workflow ([8644b87](https://github.com/visulima/vis/commit/8644b87f2f89dc24990227f506bfb1c5bd3add7e))
24
+ * **vis:** refuse a workflow partition whose target reaches itself through another target ([d7b41ad](https://github.com/visulima/vis/commit/d7b41ad59cad27f7ed71ed74d4fbafbf8d849cd7))
25
+ * **vis:** reject a GitLab cache directory that climbs out of the project through an inner `..` ([a856f4e](https://github.com/visulima/vis/commit/a856f4e9f1b256fd1bb6e23ac230e7cdb10f3e1b))
26
+ * **vis:** run a dependency's finally-task once, after the dependencies ([6e7ac42](https://github.com/visulima/vis/commit/6e7ac42a1b9ee528df9123e113b144dec873a1fa))
27
+
28
+ ### Performance Improvements
29
+
30
+ * **vis:** do not re-exec Node with a larger heap for vis fmt ([e69f91b](https://github.com/visulima/vis/commit/e69f91b61023e4c1e605d0fb8651f1fb066abc33))
31
+
32
+ ### Reverts
33
+
34
+ * drop the per-target project query from the CI workflow generator ([4c8a2be](https://github.com/visulima/vis/commit/4c8a2be7d69898aae22f760ccf9e8d59c2c73d30))
35
+
36
+ ### Documentation
37
+
38
+ * **vis:** describe the drift check's `--provider` flag ([08baa36](https://github.com/visulima/vis/commit/08baa3685dc941f76b4104af58ae6aea6794e40f))
39
+
40
+ ### Miscellaneous Chores
41
+
42
+ * **vis:** regenerate the command manifest for the dependency-scope flags ([8f84bbd](https://github.com/visulima/vis/commit/8f84bbd89bfde24984fc72a028df6b76af48f7fb))
43
+
44
+ ### Code Refactoring
45
+
46
+ * **vis:** drop redundant parentheses in the YAML list renderer ([c126d40](https://github.com/visulima/vis/commit/c126d40f59015bfbbd7c81c53b480e332b114a33))
47
+ * **vis:** drop unused ci-workflow exports ([99ec322](https://github.com/visulima/vis/commit/99ec322cbeec7b8bf0ec48bc9aec7f80fd3f5740))
48
+ * **vis:** replace an identity map with a type guard ([ea66017](https://github.com/visulima/vis/commit/ea66017674594a4c0a8c66f56684361191e140e1))
49
+
50
+ ### Tests
51
+
52
+ * **vis:** add a formatter benchmark of vis fmt, the bundled oxfmt and bun fmt ([#166](https://github.com/visulima/vis/issues/166)) ([002c9aa](https://github.com/visulima/vis/commit/002c9aabb684990fb67b34c61c2398b257488923))
53
+ * **vis:** write the GitLab limit test's layer helper with a block body ([7eb69f1](https://github.com/visulima/vis/commit/7eb69f1e4b09df25b2eb360debed031d4266df4b))
54
+
55
+
56
+ ### Dependencies
57
+
58
+ * **@visulima/task-runner:** upgraded to 3.1.0-next.1
59
+
1
60
  ## @visulima/vis [7.1.0-next.6](https://github.com/visulima/vis/compare/@visulima/vis@7.1.0-next.5...@visulima/vis@7.1.0-next.6) (2026-11-22)
2
61
 
3
62
  ### Features
package/README.md CHANGED
@@ -263,7 +263,7 @@ When aube is the installer, `vis doctor` surfaces aube's effective hardening pos
263
263
  | `vis secrets [paths]` | | Scan for hardcoded secrets / credentials (Rust-native) |
264
264
  | `vis toolchain <cmd>` | | Inspect / delegate to the version manager (proto, mise, fnm, volta…) |
265
265
  | `vis lint [files]` | | Orchestrate detected source-code linters (oxlint, biome, eslint, stylelint) |
266
- | `vis fmt [files]` | | Orchestrate detected formatters (oxfmt, biome, dprint, prettier) |
266
+ | `vis fmt [files]` | | Format with the bundled oxfmt, or run the detected formatters (biome, dprint, ruff) |
267
267
  | `vis staged` | | Run tasks on staged files (built-in `lint-staged` replacement) |
268
268
  | `vis migrate <type>` | | Migrate from other tools β€” now including `gitleaks` and `secretlint` |
269
269
 
package/dist/bin.js CHANGED
@@ -1 +1 @@
1
- import"./packem_shared/compile-cache-DoMHRsRZ.js";import"./packem_shared/bin-D1zq7wxi.js";
1
+ import"./packem_shared/compile-cache-DoMHRsRZ.js";import"./packem_shared/bin-BaReRSyo.js";
package/dist/binx.js CHANGED
@@ -1,3 +1,3 @@
1
1
  #!/usr/bin/env node
2
- import{a as r,x as i,i as c,d as a,r as d}from"./packem_shared/vis-user-error-6sSghaC9.js";import{t as n}from"./packem_shared/compile-cache-DoMHRsRZ.js";import{g as o}from"./packem_shared/package-version-VdULnxr1.js";process.argv.includes("--no-color")&&(process.env.NO_COLOR="1",process.env.FORCE_COLOR="0");process.argv.slice(2).some(s=>s==="--version"||s==="-v"||s==="-V")&&(process.stdout.write(`${o()}
2
+ import{a as r,x as i,i as c,d as a,r as d}from"./packem_shared/vis-user-error-DhgW3DzD.js";import{t as n}from"./packem_shared/compile-cache-DoMHRsRZ.js";import{g as o}from"./packem_shared/package-version-BOK3IncQ.js";process.argv.includes("--no-color")&&(process.env.NO_COLOR="1",process.env.FORCE_COLOR="0");process.argv.slice(2).some(s=>s==="--version"||s==="-v"||s==="-V")&&(process.stdout.write(`${o()}
3
3
  `),process.exit(0));process.argv.splice(2,0,"dlx");n();const e=r("visx",{packageName:"visx",packageVersion:o()}),p=process.argv.includes("--debug")||!!process.env.DEBUG;e.addPlugin(i({concise:c,detailed:p,exitOnError:!1}));e.addCommand(a);d(e);
@@ -1,6 +1,18 @@
1
1
  import { TargetConfiguration, ChildEnvOptions, TaskResult, Task, FingerprintContributor, ConstraintsConfig, NamedInputs, TaskRunnerOptions } from '@visulima/task-runner';
2
2
  export type { FingerprintContributor } from '@visulima/task-runner';
3
+ import { FormatConfig, OxfmtOverrideConfig } from 'oxfmt';
3
4
  import { VisReleaseConfig } from "../release/types.js";
5
+ /** Formatting options accepted by oxfmt, as declared by the `oxfmt` package. */
6
+ type OxfmtOptions = FormatConfig;
7
+ /** A per-glob options override, in oxfmt's own shape. */
8
+ type FmtOverride = OxfmtOverrideConfig;
9
+ /**
10
+ * Which engine `vis fmt` uses.
11
+ * - `auto`: the bundled oxfmt, unless the workspace uses biome, dprint or ruff format.
12
+ * - `oxfmt`: always the bundled oxfmt.
13
+ * - `prettier`: the detected-adapter orchestration, with Prettier staying in charge.
14
+ */
15
+ type FmtEngine = "auto" | "oxfmt" | "prettier";
4
16
  /** Adapter IDs that can format (adapter `kind` is `"fmt"` or `"both"`). */
5
17
  type FmtAdapterId = "biome" | "dprint" | "oxfmt" | "prettier" | "ruff-fmt";
6
18
  /** Adapter IDs that can lint (adapter `kind` is `"lint"` or `"both"`). */
@@ -683,6 +695,165 @@ interface VisPlugin {
683
695
  */
684
696
  setup?: (hooks: Hookable<VisHooks>) => Promise<void> | void;
685
697
  }
698
+ /** CI providers `vis sync ci-workflow` can render a workflow for. */
699
+ type CiWorkflowProvider = "github" | "gitlab";
700
+ /** A step added to the generated GitHub workflow. Exactly one of `run` and `uses` is required. */
701
+ interface CiGithubStep {
702
+ "continue-on-error"?: boolean;
703
+ env?: Record<string, string>;
704
+ /** A GitHub expression, e.g. `always()` or `github.event_name == 'push'`. */
705
+ if?: string;
706
+ name: string;
707
+ run?: string;
708
+ shell?: string;
709
+ "timeout-minutes"?: number;
710
+ /** An action reference. Pin it to a commit SHA (`owner/action@&lt;sha>`), as the generated steps are. */
711
+ uses?: string;
712
+ with?: Record<string, boolean | number | string>;
713
+ "working-directory"?: string;
714
+ }
715
+ /** A service container for the GitHub job (`jobs.&lt;id>.services`). */
716
+ interface CiGithubService {
717
+ credentials?: {
718
+ password: string;
719
+ username: string;
720
+ };
721
+ env?: Record<string, string>;
722
+ image: string;
723
+ /** Docker `create` options, e.g. `--health-cmd pg_isready`. */
724
+ options?: string;
725
+ ports?: (number | string)[];
726
+ volumes?: string[];
727
+ }
728
+ /** Additions to the generated GitHub Actions workflow. */
729
+ interface CiGithubWorkflowConfig {
730
+ /** Job-level environment variables, available to every step. Use `${{ secrets.NAME }}` for secrets. */
731
+ env?: Record<string, string>;
732
+ /**
733
+ * Permissions added to the workflow's default `contents: read`, e.g.
734
+ * `{ "id-token": "write" }` for OIDC.
735
+ */
736
+ permissions?: Record<string, "none" | "read" | "write">;
737
+ /** Service containers the job needs, keyed by service name (also its hostname). */
738
+ services?: Record<string, CiGithubService>;
739
+ steps?: {
740
+ /** Steps after all targets ran, e.g. a coverage upload (add `if: always()` to run them after a failure). */
741
+ after?: CiGithubStep[];
742
+ /** Steps after the toolchains are installed and before anything runs, e.g. starting `docker compose`. */
743
+ afterSetup?: CiGithubStep[];
744
+ };
745
+ }
746
+ /** A service container for every GitLab job (`services:`). */
747
+ type CiGitlabService = string | {
748
+ alias?: string;
749
+ command?: string[];
750
+ name: string;
751
+ variables?: Record<string, string>;
752
+ };
753
+ /** Additions to the generated GitLab CI file. They apply to every job. */
754
+ interface CiGitlabWorkflowConfig {
755
+ /** Commands after each job's script, e.g. collecting reports. */
756
+ afterScript?: string[];
757
+ /** Commands after the install and before each job's script. */
758
+ beforeScript?: string[];
759
+ /** Image for every job instead of `node:&lt;nodeVersion>`. It must have Node.js, which vis runs on. */
760
+ image?: string;
761
+ services?: CiGitlabService[];
762
+ /**
763
+ * Stage for every generated job. It has to be one of the `stages:` of the pipeline that includes the file.
764
+ * @default "test"
765
+ */
766
+ stage?: string;
767
+ /** Runner tags that pick which runners take the jobs. */
768
+ tags?: string[];
769
+ /** Variables for every job. Use masked CI/CD variables for secrets. */
770
+ variables?: Record<string, string>;
771
+ }
772
+ /** A target with settings of its own. */
773
+ interface CiWorkflowTargetConfig {
774
+ /** Environment variables for this target's step (GitHub) or job (GitLab). */
775
+ env?: Record<string, string>;
776
+ name: string;
777
+ }
778
+ /**
779
+ * Settings for the CI workflow that `vis sync ci-workflow` generates.
780
+ *
781
+ * On GitHub the workflow is a single job: it builds the dependencies of every
782
+ * listed target once (`vis ci … --deps-only`), then runs the targets as
783
+ * GitHub Actions `parallel:` step groups (`--skip-deps`). On GitLab each
784
+ * target becomes its own job, and a partitioned target uses `parallel: N`.
785
+ */
786
+ interface CiWorkflowConfig {
787
+ /**
788
+ * Run only the projects affected by the change (`vis ci`). Set to `false`
789
+ * to run every project (`vis run`).
790
+ * @default true
791
+ */
792
+ affected?: boolean;
793
+ /**
794
+ * Branches whose pushes run the workflow, besides pull/merge requests.
795
+ * Defaults to `[defaultBase ?? "main"]`.
796
+ */
797
+ branches?: string[];
798
+ /**
799
+ * Run `build` before every other listed target that `dependsOn` does not
800
+ * already order relative to it. Most workspaces never declare that
801
+ * `test` or `typecheck` needs the dependencies' `dist`, because a
802
+ * sequential CI job built first anyway; running them in parallel with
803
+ * `build` would race. Set to `false` when your `dependsOn` is complete.
804
+ * @default true
805
+ */
806
+ buildFirst?: boolean;
807
+ /**
808
+ * Run `vis sync ci-workflow --check` in the workflow, so CI fails when the
809
+ * committed workflow no longer matches this config.
810
+ * @default true
811
+ */
812
+ checkDrift?: boolean;
813
+ /** Additions to the GitHub Actions workflow: env, permissions, services and extra steps. */
814
+ github?: CiGithubWorkflowConfig;
815
+ /** Additions to the GitLab CI file: image, variables, scripts, services and runner tags. */
816
+ gitlab?: CiGitlabWorkflowConfig;
817
+ /**
818
+ * Node.js version installed by the workflow. Defaults to
819
+ * `toolchain.tools.node`, then `"22"`.
820
+ */
821
+ nodeVersion?: string;
822
+ /**
823
+ * Split a target's tasks into N shards that run at the same time
824
+ * (`--partition=k/N`), e.g. `{ test: 3 }`. On GitHub each shard is a step
825
+ * in the same `parallel:` group, so a group holds at most 10 steps.
826
+ */
827
+ partitions?: Record<string, number>;
828
+ /**
829
+ * Which providers to generate a workflow for. Detected when unset: from
830
+ * the CI files in the repository, then the CI environment or git remote.
831
+ */
832
+ providers?: CiWorkflowProvider[];
833
+ /**
834
+ * GitHub runner label.
835
+ * @default "ubuntu-latest"
836
+ */
837
+ runsOn?: string;
838
+ /**
839
+ * Targets to run. A target that depends on another listed target (through
840
+ * `dependsOn`, directly or via unlisted targets) runs in a later group;
841
+ * the rest run at the same time. Defaults to whichever of lint,
842
+ * typecheck, lint:types, build and test exist in the workspace. Use the
843
+ * object form to give a target environment variables.
844
+ */
845
+ targets?: (CiWorkflowTargetConfig | string)[];
846
+ /**
847
+ * Minutes before the CI job is cancelled (`timeout-minutes` on GitHub,
848
+ * `timeout` on GitLab).
849
+ * @default 60
850
+ */
851
+ timeoutMinutes?: number;
852
+ }
853
+ interface CiConfig {
854
+ /** The workflow generated by `vis sync ci-workflow`. */
855
+ workflow?: CiWorkflowConfig;
856
+ }
686
857
  /**
687
858
  * Recognised input sources for the codeowners aggregator.
688
859
  *
@@ -756,6 +927,16 @@ interface LintFmtAdapterOverride {
756
927
  */
757
928
  extraArgs?: string[];
758
929
  }
930
+ /**
931
+ * `fmt.adapters.oxfmt`: the shared overrides plus the switch for the oxfmt that ships with vis.
932
+ */
933
+ interface OxfmtAdapterOverride extends LintFmtAdapterOverride {
934
+ /**
935
+ * Set to `false` to keep running the project's own `oxfmt` through the adapter orchestration
936
+ * instead of the bundled one. Defaults to `true`.
937
+ */
938
+ builtin?: boolean;
939
+ }
759
940
  /**
760
941
  * One family of upstream-coupled packages.
761
942
  *
@@ -1999,6 +2180,11 @@ interface VisConfig {
1999
2180
  * @default false
2000
2181
  */
2001
2182
  branchScopedCache?: boolean;
2183
+ /**
2184
+ * CI settings. `ci.workflow` drives the GitHub Actions / GitLab CI
2185
+ * workflow that `vis sync ci-workflow` generates.
2186
+ */
2187
+ ci?: CiConfig;
2002
2188
  /**
2003
2189
  * Code ownership configuration. Controls how `vis sync codeowners`
2004
2190
  * renders the generated CODEOWNERS file.
@@ -2150,20 +2336,24 @@ interface VisConfig {
2150
2336
  */
2151
2337
  fileGroups?: Record<string, string[]>;
2152
2338
  /**
2153
- * Configuration for `vis fmt` β€” the formatter orchestrator.
2339
+ * Configuration for `vis fmt`.
2340
+ *
2341
+ * By default `vis fmt` formats with the oxfmt that ships with vis, so a workspace needs no setup.
2342
+ * The formatting options come from the first of these sources that exists, used whole (never merged):
2343
+ * `fmt.options` here, then an `.oxfmtrc.json(c)` / `oxfmt.config.ts` file, then a Prettier config
2344
+ * (mapped to oxfmt options), then oxfmt's defaults. Note that oxfmt's default `printWidth` is 100;
2345
+ * a Prettier config without one maps to Prettier's 80.
2154
2346
  *
2155
- * Tunes adapter detection precedence, per-extension routing, and
2156
- * per-adapter overrides. Flags on the CLI always win over config.
2347
+ * A workspace that uses biome, dprint or ruff format keeps the adapter orchestration: vis runs every
2348
+ * detected formatter, routed by extension. `fmt.engine` overrides that choice.
2157
2349
  *
2158
- * The default fmt precedence is `oxfmt β†’ biome β†’ dprint β†’ prettier`.
2159
- * When multiple adapters claim the same extension,
2160
- * the first in this order owns it unless overridden here.
2350
+ * Flags on the CLI always win over config.
2161
2351
  * @example
2162
2352
  * ```
2163
2353
  * fmt: {
2164
- * order: ["biome", "prettier"],
2165
- * extensionOverrides: { md: "dprint" },
2166
- * adapters: { dprint: { enabled: false } },
2354
+ * options: { printWidth: 100, singleQuote: true },
2355
+ * overrides: [{ files: ["*.md"], options: { proseWrap: "always" } }],
2356
+ * ignorePatterns: ["generated/**"],
2167
2357
  * }
2168
2358
  * ```
2169
2359
  */
@@ -2171,22 +2361,47 @@ interface VisConfig {
2171
2361
  /**
2172
2362
  * Per-adapter overrides. Keyed by `AdapterId`. Set
2173
2363
  * `enabled: false` to skip an adapter even when detected, or
2174
- * `extraArgs` to append flags verbatim.
2364
+ * `extraArgs` to append flags verbatim. `enabled: false` on `oxfmt`
2365
+ * also turns the bundled oxfmt off.
2175
2366
  */
2176
- adapters?: Partial<Record<FmtAdapterId, LintFmtAdapterOverride>>;
2367
+ adapters?: { [Id in Exclude<FmtAdapterId, "oxfmt">]?: LintFmtAdapterOverride; } & {
2368
+ oxfmt?: OxfmtAdapterOverride;
2369
+ };
2370
+ /**
2371
+ * Which formatter runs.
2372
+ * - `auto` (default): the bundled oxfmt, unless biome, dprint or ruff format is detected.
2373
+ * - `oxfmt`: always the bundled oxfmt, and no other formatter.
2374
+ * - `prettier`: the adapter orchestration, with Prettier staying in charge.
2375
+ * @default "auto"
2376
+ */
2377
+ engine?: FmtEngine;
2177
2378
  /**
2178
2379
  * Pin a file extension (without the leading dot) to a specific
2179
2380
  * adapter, overriding the registry's "first detected adapter
2180
2381
  * wins" routing. Use to e.g. send `.md` to `dprint` even when
2181
- * both prettier and dprint are present.
2382
+ * both prettier and dprint are present. Applies to the adapter
2383
+ * orchestration only.
2182
2384
  */
2183
2385
  extensionOverrides?: Record<string, FmtAdapterId>;
2386
+ /**
2387
+ * Files the bundled oxfmt skips, relative to the workspace root. Same shape as
2388
+ * oxfmt's `ignorePatterns`. A pattern containing `..` is rejected.
2389
+ */
2390
+ ignorePatterns?: string[];
2391
+ /**
2392
+ * Formatting options for the bundled oxfmt, in oxfmt's own names (`printWidth`, `semi`,
2393
+ * `singleQuote`, `sortImports`, ...). Used instead of any `.oxfmtrc` or Prettier config.
2394
+ */
2395
+ options?: OxfmtOptions;
2184
2396
  /**
2185
2397
  * Override the adapter precedence order. Adapters omitted from
2186
2398
  * this list still run (appended at the end in registry order),
2187
2399
  * but those listed earlier get priority for extension routing.
2400
+ * Applies to the adapter orchestration only.
2188
2401
  */
2189
2402
  order?: FmtAdapterId[];
2403
+ /** File-specific option overrides for the bundled oxfmt. Later entries win. A `files` or `excludeFiles` glob containing `..` is rejected. */
2404
+ overrides?: FmtOverride[];
2190
2405
  };
2191
2406
  /**
2192
2407
  * Gems as task projects. Off by default: each `*.gemspec` directory (except `vendor`,
@@ -1,4 +1,4 @@
1
- import{createRequire as O}from"node:module";import{v as j,e as l,m as S}from"../packem_shared/index-0dnGN3GP.js";import{i as A}from"./ts-loader.js";import{m as R}from"../packem_shared/target-merge-ya19LiWB.js";import{otelPlugin as ue}from"../packem_shared/otelPlugin-D8LL2-4L.js";import{definePlugin as le}from"../packem_shared/definePlugin-DoUcoYSy.js";import{y as b}from"../packem_shared/isAccessibleSync-DYKTrrvc-CBsMZhj-.js";let x;const _=e=>(x??=O(import.meta.url))(e),c=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,h=e=>{if(typeof c<"u"&&c.versions&&c.versions.node){const[s,t]=c.versions.node.split(".").map(Number);if(s>22||s===22&&t>=3||s===20&&t>=16)return c.getBuiltinModule(e)}return _(e)},{readdirSync:g}=h("node:fs"),{createRequire:E}=h("node:module");class f extends Error{chain;constructor(s,t,o){super(s,o),this.name=this.constructor.name,this.chain=t}}class V extends f{constructor(s,t){const o=[...t,`${s} (re-enters)`].join(" β†’ ");super(`Config cycle: ${o}`,t)}}class T extends f{filePath;removedKeys;constructor(s,t,o){const n=[`${s} uses removed keys.`,""];for(const r of o){const i=r.location?` (at ${r.location})`:"";n.push(` β€’ ${r.name}${i} β†’ renamed to \`${r.renamedTo}\``);for(const a of r.children??[])n.push(` ↳ ${a.name} β†’ renamed to \`${a.renamedTo}\``)}n.push("","Run `vis migrate self` to auto-rewrite the config (use --dry-run to preview)."),super(n.join(`
1
+ import{createRequire as O}from"node:module";import{v as j,e as l,m as S}from"../packem_shared/index-zq6Ehql6.js";import{i as A}from"./ts-loader.js";import{m as R}from"../packem_shared/target-merge-ya19LiWB.js";import{otelPlugin as ue}from"../packem_shared/otelPlugin-D8LL2-4L.js";import{definePlugin as le}from"../packem_shared/definePlugin-DoUcoYSy.js";import{y as b}from"../packem_shared/isAccessibleSync-DYKTrrvc-CKahNmLy.js";let x;const _=e=>(x??=O(import.meta.url))(e),c=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,h=e=>{if(typeof c<"u"&&c.versions&&c.versions.node){const[s,t]=c.versions.node.split(".").map(Number);if(s>22||s===22&&t>=3||s===20&&t>=16)return c.getBuiltinModule(e)}return _(e)},{readdirSync:g}=h("node:fs"),{createRequire:E}=h("node:module");class f extends Error{chain;constructor(s,t,o){super(s,o),this.name=this.constructor.name,this.chain=t}}class V extends f{constructor(s,t){const o=[...t,`${s} (re-enters)`].join(" β†’ ");super(`Config cycle: ${o}`,t)}}class T extends f{filePath;removedKeys;constructor(s,t,o){const n=[`${s} uses removed keys.`,""];for(const r of o){const i=r.location?` (at ${r.location})`:"";n.push(` β€’ ${r.name}${i} β†’ renamed to \`${r.renamedTo}\``);for(const a of r.children??[])n.push(` ↳ ${a.name} β†’ renamed to \`${a.renamedTo}\``)}n.push("","Run `vis migrate self` to auto-rewrite the config (use --dry-run to preview)."),super(n.join(`
2
2
  `),t),this.filePath=s,this.removedKeys=o}}class y extends f{constructor(s,t,o){const n=o instanceof Error?o.message:String(o),r=t.length>0?`
3
3
  Chain: ${t.join(" β†’ ")}`:"";super(`Failed to load ${s}: ${n}${r}`,t,{cause:o})}}const D=e=>e.join(" β†’ ");class p extends f{constructor(s,t,o){const n=t.length>0?t[t.length-1]:"<unknown>",r=o.length>0?`
4
4
  Tried:
@@ -1,2 +1,2 @@
1
- import{F as f}from"../packem_shared/index.server-Ca_EEVfw.js";import{p as i}from"./cli-main.js";import{s as d}from"../packem_shared/scan-progress-BaCJp5nr.js";import{D as p,s as D}from"../packem_shared/osv-bloom-DU6avR2k.js";const h=o=>o?.security?.audit?.advisories?.bloom??{},u=o=>o>=1e3?`${(o/1e3).toFixed(1)}s`:`${Math.round(o)}ms`,$=o=>o<1024?`${o} B`:o<1024*1024?`${(o/1024).toFixed(1)} KB`:`${(o/(1024*1024)).toFixed(1)} MB`,b=async({options:o,visConfig:m,workspaceRoot:n})=>{if(!n)throw new Error("Could not determine workspace root. Run this command inside a workspace.");const a=o.format==="json",c=h(m),l=o.source??c.source??p,r=d([{id:"bloom",label:"Sync osv-bloom prefilter"}],{live:!a});let e,t;try{r.start("bloom");const s=Date.now();e=await D({allowedHosts:c.allowedHosts,cacheDir:o.cacheDir,force:!!o.force,source:l,workspaceRoot:n}),e.upToDate?r.finish("bloom","ok",`up to date Β· ${u(Date.now()-s)}`):r.finish("bloom","ok",`${e.manifest.entryCount.toLocaleString()} entries Β· ${$(e.bytesOnDisk)} Β· ${u(e.durationMs)}`)}catch(s){t=s instanceof Error?s.message:String(s),r.finish("bloom","error",t)}finally{r.stop()}a?process.stdout.write(`${JSON.stringify({bytesOnDisk:e?.bytesOnDisk??0,cacheDir:e?.cacheDir??null,durationMs:e?.durationMs??0,error:t??null,manifest:e?.manifest??null,source:l,upToDate:e?.upToDate??!1},void 0,2)}
1
+ import{F as f}from"../packem_shared/index.server-Ca_EEVfw.js";import{p as i}from"./cli-main.js";import{s as d}from"../packem_shared/scan-progress-Dws7Gif1.js";import{D as p,s as D}from"../packem_shared/osv-bloom-DU6avR2k.js";const h=o=>o?.security?.audit?.advisories?.bloom??{},u=o=>o>=1e3?`${(o/1e3).toFixed(1)}s`:`${Math.round(o)}ms`,$=o=>o<1024?`${o} B`:o<1024*1024?`${(o/1024).toFixed(1)} KB`:`${(o/(1024*1024)).toFixed(1)} MB`,b=async({options:o,visConfig:m,workspaceRoot:n})=>{if(!n)throw new Error("Could not determine workspace root. Run this command inside a workspace.");const a=o.format==="json",c=h(m),l=o.source??c.source??p,r=d([{id:"bloom",label:"Sync osv-bloom prefilter"}],{live:!a});let e,t;try{r.start("bloom");const s=Date.now();e=await D({allowedHosts:c.allowedHosts,cacheDir:o.cacheDir,force:!!o.force,source:l,workspaceRoot:n}),e.upToDate?r.finish("bloom","ok",`up to date Β· ${u(Date.now()-s)}`):r.finish("bloom","ok",`${e.manifest.entryCount.toLocaleString()} entries Β· ${$(e.bytesOnDisk)} Β· ${u(e.durationMs)}`)}catch(s){t=s instanceof Error?s.message:String(s),r.finish("bloom","error",t)}finally{r.stop()}a?process.stdout.write(`${JSON.stringify({bytesOnDisk:e?.bytesOnDisk??0,cacheDir:e?.cacheDir??null,durationMs:e?.durationMs??0,error:t??null,manifest:e?.manifest??null,source:l,upToDate:e?.upToDate??!1},void 0,2)}
2
2
  `):e&&(i.info(f(`Cache: ${e.cacheDir}`)),i.info(f(`Built: ${e.manifest.builtAtRfc3339}`)),t||i.success(e.upToDate?"osv-bloom prefilter up to date.":"osv-bloom prefilter synced.")),t&&(process.exitCode=1)},g=b;export{g as advisoriesBloomSyncExecute};
@@ -1,4 +1,4 @@
1
- import{createRequire as je}from"node:module";import{z as N,e as g,$ as _e,m as V}from"../packem_shared/index-0dnGN3GP.js";import{L as Re,q as X,u as oe,R as C,O as W,X as De,e as J,p as P,g as ce,F as I,f as Oe,G as ie,J as H,h as le,i as D}from"../packem_shared/registry-TXpTtpgS.js";import{L as ue}from"../packem_shared/index-CIdjkZgt.js";import{y as h}from"../packem_shared/isAccessibleSync-DYKTrrvc-CBsMZhj-.js";import{U as A,h as O,e as Le,i as Me}from"../packem_shared/env-sb3SOT-b.js";import{f as Ue}from"../packem_shared/removeSync-g1D5kONg-jOsRSIIv.js";import{p as b}from"../packem_shared/package-version-VdULnxr1.js";import{g as pe,T as fe,l as Wt}from"../packem_shared/npmrc-CIvOb61L.js";import{p as cn}from"../packem_shared/npmrc-CIvOb61L.js";import{O as ge}from"../packem_shared/renderToString-DR0zDUjh-CdBv7J9a.js";import{q as We}from"../packem_shared/table-Dc3wOjzc.js";import{f as Ie}from"../packem_shared/osv-DaMZpVWl.js";import{a as Be}from"../packem_shared/index--eV4qIz5.js";import{a as Z}from"../packem_shared/advisories-BnFPhsl1.js";let Ce;const Ae=t=>(Ce??=je(import.meta.url))(t),j=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,xe=t=>{if(typeof j<"u"&&j.versions&&j.versions.node){const[e,n]=j.versions.node.split(".").map(Number);if(e>22||e===22&&n>=3||e===20&&n>=16)return j.getBuiltinModule(t)}return Ae(t)},{createInterface:Fe}=xe("node:readline"),G=["dependencies","devDependencies","optionalDependencies"],Ge=new Set([...G,"overrides","peerDependencies","pnpm.overrides","resolutions"]),x=t=>{const e=t.lastIndexOf(":");if(e===-1)return;const n=t.slice(e+1);if(Ge.has(n))return{depType:n,relativePath:t.slice(0,e)}},L=t=>{const e=ue("vis",{create:!0,cwd:t});if(!e)throw new Error("Cannot resolve cache directory. Ensure node_modules exists in your workspace. Run your package manager's install command first.");return g(e,"backup")},Y=(t,e)=>e==="bun"?g(t,"package.json"):g(t,"pnpm-workspace.yaml"),K=(t,e)=>{const n=L(t),s=new Set;for(const a of e){const r=x(a.catalogName);r&&s.add(r.relativePath==="."?"package.json":g(r.relativePath,"package.json"))}if(s.size!==0){O(n);for(const a of s){const r=g(t,a);if(h(r)){const o=g(n,a),c=V(o);O(c),A(o,N(r))}}return n}},q=(t,e)=>{const n=Y(t,e),s=L(t);return g(s,`${_e(n)}.bak`)},Ve=(t,e,n)=>{if((e==="npm"||e==="yarn")&&n)return K(t,n);let s;const a=Y(t,e);if(h(a)&&(s=q(t,e),O(V(s)),A(s,N(a))),n){const r=n.filter(o=>x(o.catalogName));r.length>0&&K(t,r)}return s},Xe=t=>{const e=L(t);if(!h(e))return!1;for(const n of Re(e,{includeDirs:!1})){const s=n.path.slice(e.length+1),a=g(t,s);A(a,N(n.path))}return Ue(e),!0},Xt=(t,e)=>{if(e==="npm"||e==="yarn")return Xe(t);const n=Y(t,e),s=q(t,e);if(!h(s))return!1;const a=N(s);return A(n,a),!0},Jt=(t,e)=>{if(e==="npm"||e==="yarn")try{const n=L(t);return h(n)}catch{return!1}try{return h(q(t,e))}catch{return!1}},de=t=>{if(h(t))try{return b(t)}catch{return}},Je=t=>{const e=de(g(t,"package.json"));return!!(e?.workspaces?.catalog||e?.workspaces?.catalogs)},He=t=>{const e=new Map;if(t.workspaces?.catalog&&typeof t.workspaces.catalog=="object"&&e.set("default",new Map(Object.entries(t.workspaces.catalog))),t.workspaces?.catalogs&&typeof t.workspaces.catalogs=="object")for(const[n,s]of Object.entries(t.workspaces.catalogs))s&&typeof s=="object"&&e.set(n,new Map(Object.entries(s)));return e},Ye=t=>{const e=de(g(t,"package.json"));return e?He(e):new Map},qe=(t,e,n)=>{const s=g(t,"package.json"),a=b(s);for(const r of e)if(r.catalogName==="default")a.workspaces?.catalog&&(a.workspaces.catalog[r.packageName]=r.newRange);else{const o=a.workspaces?.catalogs?.[r.catalogName];o&&(o[r.packageName]=r.newRange)}X(s,a,{indent:oe(s,{useEditorconfig:n}),overwrite:!0})},ze=/\*+/g,Qe=/[.+^${}()|[\]\\]/g,ee=new Map,E=(t,e)=>{let n=ee.get(e);if(!n){const a=e.replaceAll(ze,"*").replaceAll(Qe,String.raw`\$&`);n=new RegExp(`^${a.replaceAll("*",".*").replaceAll("?",".")}$`),ee.set(e,n)}return n.test(t)},me=(t,e,n)=>n.some(s=>E(t,s))?!1:e.length>0?e.some(s=>E(t,s)):!0,te=new Map,he=(t,e,n)=>{if(!n)return e;const s=n[t];if(s!==void 0)return s;for(const[a,r]of Object.entries(n))if(a!==t){if(a.startsWith("/")&&a.endsWith("/")){let o=te.get(a);if(o||(o=new RegExp(a.slice(1,-1)),te.set(a,o)),o.test(t))return r}else if(E(t,a))return r}return e},Ze=/^(?:'([^']+)'|"([^"]+)"|([^:\s]+)):\s*(?:'([^']+)'|"([^"]+)"|(\S+))/,Ke=/^catalog:/m,et=/^catalogs:/m,ke=/^['"]|['"]$/g,we=t=>{const e=Ze.exec(t);if(!e)return;const n=e[1]??e[2]??e[3],s=e[4]??e[5]??e[6];if(!(!n||!s))return[n,s]},ye=(t,e,n,s)=>{t.has(e)||t.set(e,new Map);const a=t.get(e);a&&a.set(n,s)},tt=(t,e,n)=>{if(n<2)return;const s=we(e);s&&ye(t,"default",s[0],s[1])},nt=(t,e,n,s)=>{if(n===2&&e.endsWith(":"))return e.slice(0,-1).trim().replaceAll(ke,"");if(n>=4&&s){const a=we(e);a&&ye(t,s,a[0],a[1])}return s},$e=t=>t==="catalog:"||t.startsWith("catalog:")?"catalog":t==="catalogs:"||t.startsWith("catalogs:")?"catalogs":"none",st=t=>{const e=new Map;let n="none",s="";for(const a of t.split(`
1
+ import{createRequire as je}from"node:module";import{z as N,e as g,$ as _e,m as V}from"../packem_shared/index-zq6Ehql6.js";import{L as Re,q as X,u as oe,R as C,O as W,X as De,e as J,p as P,g as ce,F as I,f as Oe,G as ie,J as H,h as le,i as D}from"../packem_shared/registry-ClmannRw.js";import{L as ue}from"../packem_shared/index-CIdjkZgt.js";import{y as h}from"../packem_shared/isAccessibleSync-DYKTrrvc-CKahNmLy.js";import{U as A,h as O,e as Le,i as Me}from"../packem_shared/env-NauRSSEC.js";import{f as Ue}from"../packem_shared/removeSync-g1D5kONg-DcG75b0G.js";import{p as b}from"../packem_shared/package-version-BOK3IncQ.js";import{g as pe,T as fe,l as Wt}from"../packem_shared/npmrc-DONprxrc.js";import{p as cn}from"../packem_shared/npmrc-DONprxrc.js";import{O as ge}from"../packem_shared/renderToString-DR0zDUjh-CBDmAXxb.js";import{q as We}from"../packem_shared/table-D1CpySxU.js";import{f as Ie}from"../packem_shared/osv-dvIA_vX3.js";import{a as Be}from"../packem_shared/index--eV4qIz5.js";import{a as Z}from"../packem_shared/advisories-CyXUdibZ.js";let Ce;const Ae=t=>(Ce??=je(import.meta.url))(t),j=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,xe=t=>{if(typeof j<"u"&&j.versions&&j.versions.node){const[e,n]=j.versions.node.split(".").map(Number);if(e>22||e===22&&n>=3||e===20&&n>=16)return j.getBuiltinModule(t)}return Ae(t)},{createInterface:Fe}=xe("node:readline"),G=["dependencies","devDependencies","optionalDependencies"],Ge=new Set([...G,"overrides","peerDependencies","pnpm.overrides","resolutions"]),x=t=>{const e=t.lastIndexOf(":");if(e===-1)return;const n=t.slice(e+1);if(Ge.has(n))return{depType:n,relativePath:t.slice(0,e)}},L=t=>{const e=ue("vis",{create:!0,cwd:t});if(!e)throw new Error("Cannot resolve cache directory. Ensure node_modules exists in your workspace. Run your package manager's install command first.");return g(e,"backup")},Y=(t,e)=>e==="bun"?g(t,"package.json"):g(t,"pnpm-workspace.yaml"),K=(t,e)=>{const n=L(t),s=new Set;for(const a of e){const r=x(a.catalogName);r&&s.add(r.relativePath==="."?"package.json":g(r.relativePath,"package.json"))}if(s.size!==0){O(n);for(const a of s){const r=g(t,a);if(h(r)){const o=g(n,a),c=V(o);O(c),A(o,N(r))}}return n}},q=(t,e)=>{const n=Y(t,e),s=L(t);return g(s,`${_e(n)}.bak`)},Ve=(t,e,n)=>{if((e==="npm"||e==="yarn")&&n)return K(t,n);let s;const a=Y(t,e);if(h(a)&&(s=q(t,e),O(V(s)),A(s,N(a))),n){const r=n.filter(o=>x(o.catalogName));r.length>0&&K(t,r)}return s},Xe=t=>{const e=L(t);if(!h(e))return!1;for(const n of Re(e,{includeDirs:!1})){const s=n.path.slice(e.length+1),a=g(t,s);A(a,N(n.path))}return Ue(e),!0},Xt=(t,e)=>{if(e==="npm"||e==="yarn")return Xe(t);const n=Y(t,e),s=q(t,e);if(!h(s))return!1;const a=N(s);return A(n,a),!0},Jt=(t,e)=>{if(e==="npm"||e==="yarn")try{const n=L(t);return h(n)}catch{return!1}try{return h(q(t,e))}catch{return!1}},de=t=>{if(h(t))try{return b(t)}catch{return}},Je=t=>{const e=de(g(t,"package.json"));return!!(e?.workspaces?.catalog||e?.workspaces?.catalogs)},He=t=>{const e=new Map;if(t.workspaces?.catalog&&typeof t.workspaces.catalog=="object"&&e.set("default",new Map(Object.entries(t.workspaces.catalog))),t.workspaces?.catalogs&&typeof t.workspaces.catalogs=="object")for(const[n,s]of Object.entries(t.workspaces.catalogs))s&&typeof s=="object"&&e.set(n,new Map(Object.entries(s)));return e},Ye=t=>{const e=de(g(t,"package.json"));return e?He(e):new Map},qe=(t,e,n)=>{const s=g(t,"package.json"),a=b(s);for(const r of e)if(r.catalogName==="default")a.workspaces?.catalog&&(a.workspaces.catalog[r.packageName]=r.newRange);else{const o=a.workspaces?.catalogs?.[r.catalogName];o&&(o[r.packageName]=r.newRange)}X(s,a,{indent:oe(s,{useEditorconfig:n}),overwrite:!0})},ze=/\*+/g,Qe=/[.+^${}()|[\]\\]/g,ee=new Map,E=(t,e)=>{let n=ee.get(e);if(!n){const a=e.replaceAll(ze,"*").replaceAll(Qe,String.raw`\$&`);n=new RegExp(`^${a.replaceAll("*",".*").replaceAll("?",".")}$`),ee.set(e,n)}return n.test(t)},me=(t,e,n)=>n.some(s=>E(t,s))?!1:e.length>0?e.some(s=>E(t,s)):!0,te=new Map,he=(t,e,n)=>{if(!n)return e;const s=n[t];if(s!==void 0)return s;for(const[a,r]of Object.entries(n))if(a!==t){if(a.startsWith("/")&&a.endsWith("/")){let o=te.get(a);if(o||(o=new RegExp(a.slice(1,-1)),te.set(a,o)),o.test(t))return r}else if(E(t,a))return r}return e},Ze=/^(?:'([^']+)'|"([^"]+)"|([^:\s]+)):\s*(?:'([^']+)'|"([^"]+)"|(\S+))/,Ke=/^catalog:/m,et=/^catalogs:/m,ke=/^['"]|['"]$/g,we=t=>{const e=Ze.exec(t);if(!e)return;const n=e[1]??e[2]??e[3],s=e[4]??e[5]??e[6];if(!(!n||!s))return[n,s]},ye=(t,e,n,s)=>{t.has(e)||t.set(e,new Map);const a=t.get(e);a&&a.set(n,s)},tt=(t,e,n)=>{if(n<2)return;const s=we(e);s&&ye(t,"default",s[0],s[1])},nt=(t,e,n,s)=>{if(n===2&&e.endsWith(":"))return e.slice(0,-1).trim().replaceAll(ke,"");if(n>=4&&s){const a=we(e);a&&ye(t,s,a[0],a[1])}return s},$e=t=>t==="catalog:"||t.startsWith("catalog:")?"catalog":t==="catalogs:"||t.startsWith("catalogs:")?"catalogs":"none",st=t=>{const e=new Map;let n="none",s="";for(const a of t.split(`
2
2
  `)){const r=a.trimStart(),o=a.length-r.length;if(o===0&&r.length>0&&!r.startsWith("#")){n=$e(r),n==="catalogs"&&(s="");continue}r.length===0||r.startsWith("#")||(n==="catalog"&&tt(e,r,o),n==="catalogs"&&(s=nt(e,r,o,s)))}return e},at=t=>{const e=g(t,"pnpm-workspace.yaml");if(!h(e))return!1;const n=N(e);return Ke.test(n)||et.test(n)},rt=t=>{const e=g(t,"pnpm-workspace.yaml");if(!h(e))return new Map;const n=N(e);return st(n)},ne=/[.*+?^${}()|[\]\\]/g,ot=(t,e)=>{const n=t.replaceAll(ne,String.raw`\$&`),s=e.replaceAll(ne,String.raw`\$&`);return new RegExp(String.raw`^(?:'${n}'|"${n}"|${n}):\s*['"]?${s}['"]?`)},ct=(t,e,n)=>ot(e,n).test(t),it=t=>{const e=new Map;for(const n of t){e.has(n.catalogName)||e.set(n.catalogName,new Map);const s=e.get(n.catalogName);s&&s.set(n.packageName,{newRange:n.newRange,oldRange:n.currentRange})}return e},se=(t,e,n)=>{if(!n)return t;for(const[s,{newRange:a,oldRange:r}]of n)if(ct(e,s,r))return t.replace(r,a);return t},lt=(t,e,n,s)=>{const a=t.trimStart(),r=t.length-a.length;return a.length===0||a.startsWith("#")?t:e==="catalog"&&r>=2?se(t,a,s.get("default")):e==="catalogs"&&r>=4&&n?se(t,a,s.get(n)):t},ut=(t,e)=>{const n=g(t,"pnpm-workspace.yaml"),a=N(n).split(`
3
3
  `),r=it(e);let o="none",c="";const i=[];for(const l of a){const u=l.trimStart(),p=l.length-u.length;p===0&&u.length>0&&!u.startsWith("#")&&(o=$e(u),o==="catalogs"&&(c="")),o==="catalogs"&&p===2&&u.endsWith(":")&&(c=u.slice(0,-1).trim().replaceAll(ke,"")),i.push(lt(l,o,c,r))}A(n,i.join(`
4
4
  `))},pt=/github\.com[/:]([\w.-]+)\/([\w.-]+?)(?:\.git|\/|$)/,Ht=async(t,e=1e4,n)=>{const s=[],a=new AbortController,r=setTimeout(()=>{a.abort()},e),o=async u=>{const p=`https://www.npmjs.com/package/${u.packageName}`;try{const f=n?pe(u.packageName,n):{url:"https://registry.npmjs.org"},w=f.url.replace(fe,""),y={Accept:"application/json"};f.token&&(y.Authorization=`Bearer ${f.token}`);const m=await fetch(`${w}/${u.packageName}/latest`,{headers:y,signal:a.signal});if(!m.ok)return{npmUrl:p,packageName:u.packageName};const $=(await m.json()).repository?.url;if(!$)return{npmUrl:p,packageName:u.packageName};const d=pt.exec($);if(!d)return{npmUrl:p,packageName:u.packageName,repoUrl:$};const v=d[1],T=d[2],k=`https://github.com/${v}/${T}/releases/tag/v${u.targetVersion}`;return{npmUrl:p,packageName:u.packageName,releaseUrl:k,repoUrl:`https://github.com/${v}/${T}`}}catch{return{npmUrl:p,packageName:u.packageName}}},c=Math.min(8,t.length);let i=0;const l=async()=>{for(;i<t.length;){const u=i;i+=1,s[u]=await o(t[u])}};try{await Promise.all(Array.from({length:c},()=>l()))}finally{clearTimeout(r)}return s},Yt=t=>JSON.stringify(t,void 0,2),qt=t=>t.map(e=>`${e.packageName} ${e.currentRange} β†’ ${e.newRange}`).join(`
@@ -1 +1 @@
1
- import{a as r,x as o,d as i,r as n,i as s}from"../packem_shared/vis-user-error-6sSghaC9.js";import{e as t}from"../packem_shared/index-C_7lOmB0.js";import{g as d}from"../packem_shared/package-version-VdULnxr1.js";const g=async()=>{const e=r("vis",{packageName:"vis",packageVersion:d()}),a=process.argv.includes("--debug")||!!process.env.DEBUG;e.addPlugin(o({concise:s,detailed:a,exitOnError:!1})),e.addGlobalOption({description:"Target JS runtime: node (default) or bun. Overrides VIS_RUNTIME; falls back to lockfile detection.",name:"runtime",type:String}),e.addCommand(t),e.addCommand(i),await n(e)};export{g as runExecCli};
1
+ import{a as r,x as o,d as i,r as n,i as s}from"../packem_shared/vis-user-error-DhgW3DzD.js";import{e as t}from"../packem_shared/index-OmE1O0Ys.js";import{g as d}from"../packem_shared/package-version-BOK3IncQ.js";const g=async()=>{const e=r("vis",{packageName:"vis",packageVersion:d()}),a=process.argv.includes("--debug")||!!process.env.DEBUG;e.addPlugin(o({concise:s,detailed:a,exitOnError:!1})),e.addGlobalOption({description:"Target JS runtime: node (default) or bun. Overrides VIS_RUNTIME; falls back to lockfile detection.",name:"runtime",type:String}),e.addCommand(t),e.addCommand(i),await n(e)};export{g as runExecCli};