@visulima/vis 3.0.2 → 3.0.3

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 (56) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/LICENSE.md +1 -130
  3. package/dist/bin.js +1 -1
  4. package/dist/binx.js +1 -1
  5. package/dist/packem_chunks/CONFIG_FILES.js +1 -1
  6. package/dist/packem_chunks/bloom-status.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 +168 -170
  11. package/dist/packem_chunks/fix.js +1 -1
  12. package/dist/packem_chunks/handler15.js +1 -1
  13. package/dist/packem_chunks/handler19.js +1 -1
  14. package/dist/packem_chunks/handler2.js +1 -1
  15. package/dist/packem_chunks/handler21.js +1 -1
  16. package/dist/packem_chunks/handler24.js +1 -1
  17. package/dist/packem_chunks/handler28.js +1 -1
  18. package/dist/packem_chunks/handler3.js +1 -1
  19. package/dist/packem_chunks/handler54.js +1 -1
  20. package/dist/packem_chunks/handler55.js +1 -1
  21. package/dist/packem_chunks/handler58.js +1 -1
  22. package/dist/packem_chunks/handler6.js +5 -5
  23. package/dist/packem_chunks/handler62.js +1 -1
  24. package/dist/packem_chunks/handler64.js +2 -2
  25. package/dist/packem_chunks/handler67.js +1 -1
  26. package/dist/packem_chunks/handler69.js +1 -1
  27. package/dist/packem_chunks/handler70.js +1 -1
  28. package/dist/packem_chunks/handler72.js +1 -1
  29. package/dist/packem_chunks/handler73.js +1 -1
  30. package/dist/packem_chunks/handler74.js +1 -1
  31. package/dist/packem_chunks/handler75.js +1 -1
  32. package/dist/packem_chunks/handler76.js +1 -1
  33. package/dist/packem_chunks/handler77.js +40 -40
  34. package/dist/packem_chunks/heal.js +1 -1
  35. package/dist/packem_chunks/help-command.js +1 -1
  36. package/dist/packem_chunks/list.js +1 -1
  37. package/dist/packem_chunks/prune.js +1 -1
  38. package/dist/packem_chunks/run.js +1 -1
  39. package/dist/packem_chunks/status.js +1 -1
  40. package/dist/packem_chunks/sync.js +1 -1
  41. package/dist/packem_shared/{advisories-DZd1uGqa.js → advisories-0ScpWAHV.js} +1 -1
  42. package/dist/packem_shared/{affected-selection-CoRXp5H4.js → affected-selection-BMoQWuHl.js} +1 -1
  43. package/dist/packem_shared/{ai-fix-6nXZbecQ.js → ai-fix-CKN1JGRh.js} +1 -1
  44. package/dist/packem_shared/{bin-C2eYtJ_N.js → bin-CN4heKmb.js} +1 -1
  45. package/dist/packem_shared/{osv-bloom-1JS__1or.js → osv-bloom-JYIWcH3F.js} +1 -1
  46. package/dist/packem_shared/{package-version-Bb7KGF36.js → package-version-CJxZ_B7G.js} +3 -3
  47. package/dist/packem_shared/{project-name-filter-DYaIbrXa.js → project-name-filter-DsrVo0MY.js} +1 -1
  48. package/dist/packem_shared/{scan-progress-aVHGZYWf.js → scan-progress-5uTRdC1G.js} +2 -2
  49. package/dist/packem_shared/{spinner-CbJfWYwB.js → spinner-BM_0Bj6x.js} +1 -1
  50. package/dist/packem_shared/{tabs-BilwonkM.js → tabs-UDYQ3tqt.js} +1 -1
  51. package/dist/packem_shared/target-merge-B4No-LHM.js +4 -0
  52. package/dist/packem_shared/{vis-update-app-ngwL2mRv.js → vis-update-app-zqSa2clT.js} +1 -1
  53. package/dist/packem_shared/{vis-user-error-CAu9wIbe.js → vis-user-error-Dkc97rGY.js} +1 -1
  54. package/index.js +26 -26
  55. package/package.json +11 -11
  56. package/dist/packem_shared/target-merge-DCGow6Kw.js +0 -4
package/CHANGELOG.md CHANGED
@@ -1,3 +1,15 @@
1
+ ## @visulima/vis [3.0.3](https://github.com/visulima/visulima/compare/%40visulima%2Fvis%403.0.2...%40visulima%2Fvis%403.0.3) (2026-08-18)
2
+
3
+
4
+ ### Dependencies
5
+
6
+ * **@visulima/tui:** upgraded to 4.0.2
7
+ * **@visulima/tui-kit:** upgraded to 1.0.5
8
+ * **@visulima/ansi:** upgraded to 4.2.0
9
+ * **@visulima/fs:** upgraded to 6.0.2
10
+ * **@visulima/package:** upgraded to 5.0.15
11
+ * **@visulima/tsconfig:** upgraded to 3.2.9
12
+
1
13
  ## @visulima/vis [3.0.2](https://github.com/visulima/visulima/compare/%40visulima%2Fvis%403.0.1...%40visulima%2Fvis%403.0.2) (2026-08-17)
2
14
 
3
15
 
package/LICENSE.md CHANGED
@@ -3354,7 +3354,7 @@ Repository: git+https://github.com/visulima/visulima.git
3354
3354
  > >
3355
3355
  > > # Licenses of bundled types
3356
3356
  > > The published @visulima/fs artifact additionally contains code with the following licenses:
3357
- > > MIT, (MIT OR CC0-1.0)
3357
+ > > MIT
3358
3358
  > >
3359
3359
  > > # Bundled types:
3360
3360
  > > ## @visulima/yaml
@@ -3444,135 +3444,6 @@ Repository: git+https://github.com/visulima/visulima.git
3444
3444
  > > > LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
3445
3445
  > > > OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
3446
3446
  > > > SOFTWARE.
3447
- > >
3448
- > > ---------------------------------------
3449
- > >
3450
- > > ## type-fest
3451
- > > License: (MIT OR CC0-1.0)
3452
- > > By: Sindre Sorhus
3453
- > > Repository: sindresorhus/type-fest
3454
- > >
3455
- > > > Creative Commons Legal Code
3456
- > > >
3457
- > > > CC0 1.0 Universal
3458
- > > >
3459
- > > > CREATIVE COMMONS CORPORATION IS NOT A LAW FIRM AND DOES NOT PROVIDE
3460
- > > > LEGAL SERVICES. DISTRIBUTION OF THIS DOCUMENT DOES NOT CREATE AN
3461
- > > > ATTORNEY-CLIENT RELATIONSHIP. CREATIVE COMMONS PROVIDES THIS
3462
- > > > INFORMATION ON AN "AS-IS" BASIS. CREATIVE COMMONS MAKES NO WARRANTIES
3463
- > > > REGARDING THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS
3464
- > > > PROVIDED HEREUNDER, AND DISCLAIMS LIABILITY FOR DAMAGES RESULTING FROM
3465
- > > > THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS PROVIDED
3466
- > > > HEREUNDER.
3467
- > > >
3468
- > > > Statement of Purpose
3469
- > > >
3470
- > > > The laws of most jurisdictions throughout the world automatically confer
3471
- > > > exclusive Copyright and Related Rights (defined below) upon the creator
3472
- > > > and subsequent owner(s) (each and all, an "owner") of an original work of
3473
- > > > authorship and/or a database (each, a "Work").
3474
- > > >
3475
- > > > Certain owners wish to permanently relinquish those rights to a Work for
3476
- > > > the purpose of contributing to a commons of creative, cultural and
3477
- > > > scientific works ("Commons") that the public can reliably and without fear
3478
- > > > of later claims of infringement build upon, modify, incorporate in other
3479
- > > > works, reuse and redistribute as freely as possible in any form whatsoever
3480
- > > > and for any purposes, including without limitation commercial purposes.
3481
- > > > These owners may contribute to the Commons to promote the ideal of a free
3482
- > > > culture and the further production of creative, cultural and scientific
3483
- > > > works, or to gain reputation or greater distribution for their Work in
3484
- > > > part through the use and efforts of others.
3485
- > > >
3486
- > > > For these and/or other purposes and motivations, and without any
3487
- > > > expectation of additional consideration or compensation, the person
3488
- > > > associating CC0 with a Work (the "Affirmer"), to the extent that he or she
3489
- > > > is an owner of Copyright and Related Rights in the Work, voluntarily
3490
- > > > elects to apply CC0 to the Work and publicly distribute the Work under its
3491
- > > > terms, with knowledge of his or her Copyright and Related Rights in the
3492
- > > > Work and the meaning and intended legal effect of CC0 on those rights.
3493
- > > >
3494
- > > > 1. Copyright and Related Rights. A Work made available under CC0 may be
3495
- > > > protected by copyright and related or neighboring rights ("Copyright and
3496
- > > > Related Rights"). Copyright and Related Rights include, but are not
3497
- > > > limited to, the following:
3498
- > > >
3499
- > > > i. the right to reproduce, adapt, distribute, perform, display,
3500
- > > > communicate, and translate a Work;
3501
- > > > ii. moral rights retained by the original author(s) and/or performer(s);
3502
- > > > iii. publicity and privacy rights pertaining to a person's image or
3503
- > > > likeness depicted in a Work;
3504
- > > > iv. rights protecting against unfair competition in regards to a Work,
3505
- > > > subject to the limitations in paragraph 4(a), below;
3506
- > > > v. rights protecting the extraction, dissemination, use and reuse of data
3507
- > > > in a Work;
3508
- > > > vi. database rights (such as those arising under Directive 96/9/EC of the
3509
- > > > European Parliament and of the Council of 11 March 1996 on the legal
3510
- > > > protection of databases, and under any national implementation
3511
- > > > thereof, including any amended or successor version of such
3512
- > > > directive); and
3513
- > > > vii. other similar, equivalent or corresponding rights throughout the
3514
- > > > world based on applicable law or treaty, and any national
3515
- > > > implementations thereof.
3516
- > > >
3517
- > > > 2. Waiver. To the greatest extent permitted by, but not in contravention
3518
- > > > of, applicable law, Affirmer hereby overtly, fully, permanently,
3519
- > > > irrevocably and unconditionally waives, abandons, and surrenders all of
3520
- > > > Affirmer's Copyright and Related Rights and associated claims and causes
3521
- > > > of action, whether now known or unknown (including existing as well as
3522
- > > > future claims and causes of action), in the Work (i) in all territories
3523
- > > > worldwide, (ii) for the maximum duration provided by applicable law or
3524
- > > > treaty (including future time extensions), (iii) in any current or future
3525
- > > > medium and for any number of copies, and (iv) for any purpose whatsoever,
3526
- > > > including without limitation commercial, advertising or promotional
3527
- > > > purposes (the "Waiver"). Affirmer makes the Waiver for the benefit of each
3528
- > > > member of the public at large and to the detriment of Affirmer's heirs and
3529
- > > > successors, fully intending that such Waiver shall not be subject to
3530
- > > > revocation, rescission, cancellation, termination, or any other legal or
3531
- > > > equitable action to disrupt the quiet enjoyment of the Work by the public
3532
- > > > as contemplated by Affirmer's express Statement of Purpose.
3533
- > > >
3534
- > > > 3. Public License Fallback. Should any part of the Waiver for any reason
3535
- > > > be judged legally invalid or ineffective under applicable law, then the
3536
- > > > Waiver shall be preserved to the maximum extent permitted taking into
3537
- > > > account Affirmer's express Statement of Purpose. In addition, to the
3538
- > > > extent the Waiver is so judged Affirmer hereby grants to each affected
3539
- > > > person a royalty-free, non transferable, non sublicensable, non exclusive,
3540
- > > > irrevocable and unconditional license to exercise Affirmer's Copyright and
3541
- > > > Related Rights in the Work (i) in all territories worldwide, (ii) for the
3542
- > > > maximum duration provided by applicable law or treaty (including future
3543
- > > > time extensions), (iii) in any current or future medium and for any number
3544
- > > > of copies, and (iv) for any purpose whatsoever, including without
3545
- > > > limitation commercial, advertising or promotional purposes (the
3546
- > > > "License"). The License shall be deemed effective as of the date CC0 was
3547
- > > > applied by Affirmer to the Work. Should any part of the License for any
3548
- > > > reason be judged legally invalid or ineffective under applicable law, such
3549
- > > > partial invalidity or ineffectiveness shall not invalidate the remainder
3550
- > > > of the License, and in such case Affirmer hereby affirms that he or she
3551
- > > > will not (i) exercise any of his or her remaining Copyright and Related
3552
- > > > Rights in the Work or (ii) assert any associated claims and causes of
3553
- > > > action with respect to the Work, in either case contrary to Affirmer's
3554
- > > > express Statement of Purpose.
3555
- > > >
3556
- > > > 4. Limitations and Disclaimers.
3557
- > > >
3558
- > > > a. No trademark or patent rights held by Affirmer are waived, abandoned,
3559
- > > > surrendered, licensed or otherwise affected by this document.
3560
- > > > b. Affirmer offers the Work as-is and makes no representations or
3561
- > > > warranties of any kind concerning the Work, express, implied,
3562
- > > > statutory or otherwise, including without limitation warranties of
3563
- > > > title, merchantability, fitness for a particular purpose, non
3564
- > > > infringement, or the absence of latent or other defects, accuracy, or
3565
- > > > the present or absence of errors, whether or not discoverable, all to
3566
- > > > the greatest extent permissible under applicable law.
3567
- > > > c. Affirmer disclaims responsibility for clearing rights of other persons
3568
- > > > that may apply to the Work or any use thereof, including without
3569
- > > > limitation any person's Copyright and Related Rights in the Work.
3570
- > > > Further, Affirmer disclaims responsibility for obtaining any necessary
3571
- > > > consents, permissions or other rights required for any use of the
3572
- > > > Work.
3573
- > > > d. Affirmer understands and acknowledges that Creative Commons is not a
3574
- > > > party to this document and has no duty or obligation with respect to
3575
- > > > this CC0 or use of the Work.
3576
3447
  >
3577
3448
  > ---------------------------------------
3578
3449
  >
package/dist/bin.js CHANGED
@@ -1 +1 @@
1
- import"./packem_shared/compile-cache-DoMHRsRZ.js";import"./packem_shared/bin-C2eYtJ_N.js";
1
+ import"./packem_shared/compile-cache-DoMHRsRZ.js";import"./packem_shared/bin-CN4heKmb.js";
package/dist/binx.js CHANGED
@@ -1,3 +1,3 @@
1
1
  #!/usr/bin/env node
2
- import{m as r,w as i,i as c,d as a,r as d}from"./packem_shared/vis-user-error-CAu9wIbe.js";import{t as n}from"./packem_shared/compile-cache-DoMHRsRZ.js";import{g as o}from"./packem_shared/package-version-Bb7KGF36.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{m as r,w as i,i as c,d as a,r as d}from"./packem_shared/vis-user-error-Dkc97rGY.js";import{t as n}from"./packem_shared/compile-cache-DoMHRsRZ.js";import{g as o}from"./packem_shared/package-version-CJxZ_B7G.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,4 +1,4 @@
1
- import{createRequire as G}from"node:module";import{w as _,m as L,T as O}from"../packem_shared/target-merge-DCGow6Kw.js";import{v as b,e as a,m as y}from"../packem_shared/index-DHD8wb6Z.js";import{i as q}from"./ts-loader.js";import{otelPlugin as je}from"../packem_shared/otelPlugin-D8LL2-4L.js";import{definePlugin as Oe}from"../packem_shared/definePlugin-DoUcoYSy.js";import{y as d}from"../packem_shared/isAccessibleSync-DYKTrrvc-CSnBISfV.js";import{h as p}from"../packem_shared/writeFileSync-DJoHk3Ks-CgQ-VNNT.js";import{p as $}from"../packem_shared/readJsonSync-CbryXYxN-B2aSeDpC.js";let R;const I=e=>(R??=G(import.meta.url))(e),l=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,k=e=>{if(typeof l<"u"&&l.versions&&l.versions.node){const[s,t]=l.versions.node.split(".").map(Number);if(s>22||s===22&&t>=3||s===20&&t>=16)return l.getBuiltinModule(e)}return I(e)},{createHash:w}=k("node:crypto"),{readdirSync:j,readFileSync:N}=k("node:fs"),{createRequire:F}=k("node:module");class h extends Error{chain;constructor(s,t,o){super(s,o),this.name=this.constructor.name,this.chain=t}}class K extends h{constructor(s,t){const o=[...t,`${s} (re-enters)`].join(" → ");super(`Config cycle: ${o}`,t)}}class E extends h{filePath;removedKeys;constructor(s,t,o){const r=[`${s} uses removed keys.`,""];for(const n of o){const i=n.location?` (at ${n.location})`:"";r.push(` • ${n.name}${i} → renamed to \`${n.renamedTo}\``);for(const c of n.children??[])r.push(` ↳ ${c.name} → renamed to \`${c.renamedTo}\``)}r.push("","Run `vis migrate self` to auto-rewrite the config (use --dry-run to preview)."),super(r.join(`
1
+ import{createRequire as G}from"node:module";import{L as _,m as L,T as O}from"../packem_shared/target-merge-B4No-LHM.js";import{v as b,e as a,m as y}from"../packem_shared/index-DHD8wb6Z.js";import{i as q}from"./ts-loader.js";import{otelPlugin as je}from"../packem_shared/otelPlugin-D8LL2-4L.js";import{definePlugin as Oe}from"../packem_shared/definePlugin-DoUcoYSy.js";import{y as d}from"../packem_shared/isAccessibleSync-DYKTrrvc-CSnBISfV.js";import{h as p}from"../packem_shared/writeFileSync-DJoHk3Ks-CgQ-VNNT.js";import{p as $}from"../packem_shared/readJsonSync-CbryXYxN-B2aSeDpC.js";let R;const I=e=>(R??=G(import.meta.url))(e),l=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,k=e=>{if(typeof l<"u"&&l.versions&&l.versions.node){const[s,t]=l.versions.node.split(".").map(Number);if(s>22||s===22&&t>=3||s===20&&t>=16)return l.getBuiltinModule(e)}return I(e)},{createHash:w}=k("node:crypto"),{readdirSync:j,readFileSync:N}=k("node:fs"),{createRequire:F}=k("node:module");class h extends Error{chain;constructor(s,t,o){super(s,o),this.name=this.constructor.name,this.chain=t}}class K extends h{constructor(s,t){const o=[...t,`${s} (re-enters)`].join(" → ");super(`Config cycle: ${o}`,t)}}class E extends h{filePath;removedKeys;constructor(s,t,o){const r=[`${s} uses removed keys.`,""];for(const n of o){const i=n.location?` (at ${n.location})`:"";r.push(` • ${n.name}${i} → renamed to \`${n.renamedTo}\``);for(const c of n.children??[])r.push(` ↳ ${c.name} → renamed to \`${c.renamedTo}\``)}r.push("","Run `vis migrate self` to auto-rewrite the config (use --dry-run to preview)."),super(r.join(`
2
2
  `),t),this.filePath=s,this.removedKeys=o}}class v extends h{constructor(s,t,o){const r=o instanceof Error?o.message:String(o),n=t.length>0?`
3
3
  Chain: ${t.join(" → ")}`:"";super(`Failed to load ${s}: ${r}${n}`,t,{cause:o})}}const M=e=>e.join(" → ");class m extends h{constructor(s,t,o){const r=t.length>0?t[t.length-1]:"<unknown>",n=o.length>0?`
4
4
  Tried:
@@ -1,2 +1,2 @@
1
- import{b as f,F as s,J as c}from"../packem_shared/index.server-BAjDJSEu.js";import{p as r}from"./cli-main.js";import{g as u}from"../packem_shared/osv-bloom-1JS__1or.js";const a=t=>{if(!t)return"never";const i=Date.parse(t);if(Number.isNaN(i))return t;const e=Date.now()-i;if(e<0)return t;const n=Math.floor(e/6e4);if(n<1)return"just now";if(n<60)return`${n}m ago`;const o=Math.floor(n/60);return o<24?`${o}h ago`:`${Math.floor(o/24)}d ago`},m=t=>t<1024?`${t} B`:t<1024*1024?`${(t/1024).toFixed(1)} KB`:`${(t/(1024*1024)).toFixed(1)} MB`,l=async({options:t,workspaceRoot:i})=>{if(!i)throw new Error("Could not determine workspace root. Run this command inside a workspace.");const e=await u(i,t.cacheDir);if(t.format==="json"){process.stdout.write(`${JSON.stringify(e,void 0,2)}
1
+ import{b as f,F as s,J as c}from"../packem_shared/index.server-BAjDJSEu.js";import{p as r}from"./cli-main.js";import{g as u}from"../packem_shared/osv-bloom-JYIWcH3F.js";const a=t=>{if(!t)return"never";const i=Date.parse(t);if(Number.isNaN(i))return t;const e=Date.now()-i;if(e<0)return t;const n=Math.floor(e/6e4);if(n<1)return"just now";if(n<60)return`${n}m ago`;const o=Math.floor(n/60);return o<24?`${o}h ago`:`${Math.floor(o/24)}d ago`},m=t=>t<1024?`${t} B`:t<1024*1024?`${(t/1024).toFixed(1)} KB`:`${(t/(1024*1024)).toFixed(1)} MB`,l=async({options:t,workspaceRoot:i})=>{if(!i)throw new Error("Could not determine workspace root. Run this command inside a workspace.");const e=await u(i,t.cacheDir);if(t.format==="json"){process.stdout.write(`${JSON.stringify(e,void 0,2)}
2
2
  `);return}if(r.info(`Cache: ${e.cacheDir}`),!e.present){r.warn(`No osv-bloom filter yet. Run ${f("vis advisories bloom sync")} to populate.`);return}if(e.manifest){const{manifest:o}=e;r.info(`Built: ${o.builtAtRfc3339} (${a(o.builtAtRfc3339)})`),r.info(`Fetch: ${e.fetchedAtIso??s("—")} (${a(e.fetchedAtIso)})`),r.info(`Filter: ${c(m(o.bloomByteLen))} m=${o.bloomMBits.toLocaleString()} bits k=${String(o.bloomKHashes)}`),r.info(`Set: ${o.entryCount.toLocaleString()} entries from ${o.advisoryCount.toLocaleString()} advisories (target FPR ${o.targetFpr})`),r.info(s(`Digest: ${o.setDigestSha256}`))}else r.warn("filter.bin present but manifest.json missing — `vis advisories bloom sync` will rewrite the cache.")},g=l;export{g as advisoriesBloomStatusExecute};
@@ -1,2 +1,2 @@
1
- import{F as f}from"../packem_shared/index.server-BAjDJSEu.js";import{p as i}from"./cli-main.js";import{s as d}from"../packem_shared/scan-progress-aVHGZYWf.js";import{D as p,s as D}from"../packem_shared/osv-bloom-1JS__1or.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-BAjDJSEu.js";import{p as i}from"./cli-main.js";import{s as d}from"../packem_shared/scan-progress-5uTRdC1G.js";import{D as p,s as D}from"../packem_shared/osv-bloom-JYIWcH3F.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};