@visulima/fs 5.1.0 → 6.0.1
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/CHANGELOG.md +10 -0
- package/LICENSE.md +159 -19
- package/README.md +6 -6
- package/dist/eol.js +3 -3
- package/dist/glob-parent.js +1 -1
- package/dist/glob.d.ts +54 -2
- package/dist/glob.js +1 -1
- package/dist/index.d.ts +4 -4
- package/dist/index.js +1 -1
- package/dist/ini.d.ts +2 -2
- package/dist/ini.js +1 -1
- package/dist/is-glob.js +1 -1
- package/dist/json5.d.ts +2 -2
- package/dist/json5.js +1 -1
- package/dist/jsonc.d.ts +2 -2
- package/dist/jsonc.js +1 -1
- package/dist/match.js +1 -1
- package/dist/packem_shared/FIND_UP_STOP-pQqZdUPw.js +1 -0
- package/dist/packem_shared/_commonjsHelpers-CqkleIqs.js +1 -0
- package/dist/packem_shared/assertValidFileOrDirectoryPath-CAHgg-jK.js +1 -0
- package/dist/packem_shared/build-rm-options-_U1T9rOz.js +1 -0
- package/dist/packem_shared/collect-DXVMgRiZ.js +1 -0
- package/dist/packem_shared/collectSync-jjcJdHox.js +1 -0
- package/dist/packem_shared/copy-Cv8Vvdrc.js +1 -0
- package/dist/packem_shared/copySync-JIxmcGrd.js +1 -0
- package/dist/packem_shared/emptyDir-DQ1LfO2i.js +1 -0
- package/dist/packem_shared/emptyDirSync-BXDqirP1.js +1 -0
- package/dist/packem_shared/ensureDir-qy_X-WeG.js +1 -0
- package/dist/packem_shared/{ensureDirSync-B0w9WMwE.js → ensureDirSync-ONFJBCbg.js} +1 -1
- package/dist/packem_shared/{ensureFile-waD4hDO8.js → ensureFile-q1ozF6q5.js} +1 -1
- package/dist/packem_shared/ensureFileSync-B6eR38N_.js +1 -0
- package/dist/packem_shared/ensureLink-BpsTVGAm.js +1 -0
- package/dist/packem_shared/ensureLinkSync-B5moWvh3.js +1 -0
- package/dist/packem_shared/ensureSymlink-BF0BwVPy.js +1 -0
- package/dist/packem_shared/ensureSymlinkSync-D-JzDuD7.js +1 -0
- package/dist/packem_shared/findUp-BlQ1EUhu.js +1 -0
- package/dist/packem_shared/findUpSync-CF1OXVQw.js +1 -0
- package/dist/packem_shared/glob-Cyk1H9ZL.js +1 -0
- package/dist/packem_shared/globSync-Cm0u7eCn.js +1 -0
- package/dist/packem_shared/index-CBWLeiRp.js +1 -0
- package/dist/packem_shared/index-DDkv7LRn.js +1 -0
- package/dist/packem_shared/index-DGueExxA.js +1 -0
- package/dist/packem_shared/index-ovH_d7Hf.js +11 -0
- package/dist/packem_shared/indexToLineColumn-BHKDfaPx-DS9KxkE-.js +6 -0
- package/dist/packem_shared/ini-preserve-D3Z1KcgN.js +4 -0
- package/dist/packem_shared/is-stats-identical-DOh8_0KH.js +1 -0
- package/dist/packem_shared/isAccessible-CqNOFdZu.js +1 -0
- package/dist/packem_shared/isAccessibleSync-DYKTrrvc.js +1 -0
- package/dist/packem_shared/json-value.d-DZqAihX4.d.ts +29 -0
- package/dist/packem_shared/jsonc-merge-BGm21l00.js +2 -0
- package/dist/packem_shared/map-read-error-8dAe6Qhr.js +1 -0
- package/dist/packem_shared/move-DG3P4i6Y.js +1 -0
- package/dist/packem_shared/parseJson-gfl5PTTo.js +1 -0
- package/dist/packem_shared/readFile-DbKGLwIK.js +1 -0
- package/dist/packem_shared/readFileSync-CTTHkZ_p.js +1 -0
- package/dist/packem_shared/readIni-C9VUitQm.js +1 -0
- package/dist/packem_shared/readIniSync-DhMbhDPx.js +1 -0
- package/dist/packem_shared/readJson-CClJlGok.js +1 -0
- package/dist/packem_shared/readJson5-D33tgtEU.js +1 -0
- package/dist/packem_shared/readJson5Sync-DEd-ejtp.js +1 -0
- package/dist/packem_shared/readJsonSync-CbryXYxN.js +1 -0
- package/dist/packem_shared/readJsonc-Cp1KzmVx.js +1 -0
- package/dist/packem_shared/readJsoncSync-sE30rJ5W.js +1 -0
- package/dist/packem_shared/readToml-jD08lZRN.js +1 -0
- package/dist/packem_shared/readTomlSync-0J8gIalg.js +1 -0
- package/dist/packem_shared/readYaml-C63_W9Qg.js +1 -0
- package/dist/packem_shared/readYamlSync-CuyDW6xR.js +1 -0
- package/dist/packem_shared/remove-4ofpEuH1.js +1 -0
- package/dist/packem_shared/removeSync-g1D5kONg.js +1 -0
- package/dist/packem_shared/resolve-symlink-target-D4Pb9Fjw.js +1 -0
- package/dist/packem_shared/sanitize-B1LHjdjC.js +1 -0
- package/dist/packem_shared/stripJsonComments-Do7s7No5.js +1 -0
- package/dist/packem_shared/to-uint-8-array-DlTu4L-l.js +1 -0
- package/dist/packem_shared/types.d-B-T1rDxl.d.ts +958 -0
- package/dist/packem_shared/walk-Brue5N30.js +1 -0
- package/dist/packem_shared/walk-include-aizKyl9e.js +1 -0
- package/dist/packem_shared/walkSync-BWGgTwUy.js +1 -0
- package/dist/packem_shared/writeFile-BIBP7wbK.js +1 -0
- package/dist/packem_shared/writeFileSync-DJoHk3Ks.js +1 -0
- package/dist/packem_shared/writeIni--gog68qN.js +4 -0
- package/dist/packem_shared/writeIniSync-BL_z8aMQ.js +4 -0
- package/dist/packem_shared/writeJson-DmN1UqZc.js +4 -0
- package/dist/packem_shared/writeJson5-CPRmF2K7.js +4 -0
- package/dist/packem_shared/writeJson5Sync-BiUfm-cZ.js +4 -0
- package/dist/packem_shared/writeJsonSync-BiFyXQ5h.js +4 -0
- package/dist/packem_shared/writeJsonc-B4ahk9a2.js +4 -0
- package/dist/packem_shared/writeJsoncSync-lBv1IFDo.js +4 -0
- package/dist/packem_shared/writeToml-Frvwh0Kn.js +1 -0
- package/dist/packem_shared/writeTomlSync-BvKdlKvE.js +1 -0
- package/dist/packem_shared/writeYaml-C4IGXTOo.js +1 -0
- package/dist/packem_shared/writeYamlSync-BAbWtkvq.js +1 -0
- package/dist/size.js +1 -1
- package/dist/toml.d.ts +1 -1
- package/dist/toml.js +1 -1
- package/dist/utils.d.ts +2 -2
- package/dist/utils.js +1 -1
- package/dist/yaml.d.ts +2 -2
- package/dist/yaml.js +1 -1
- package/package.json +28 -28
- package/dist/packem_shared/FIND_UP_STOP-CAwY1qU7.js +0 -1
- package/dist/packem_shared/_commonjsHelpers-CWAkuNXM.js +0 -1
- package/dist/packem_shared/assertValidFileOrDirectoryPath-BTlt945W.js +0 -1
- package/dist/packem_shared/build-rm-options-avnusYx-.js +0 -1
- package/dist/packem_shared/collect-Dbo3K4iq.js +0 -1
- package/dist/packem_shared/collectSync-BLLtRqQ4.js +0 -1
- package/dist/packem_shared/copy-DiR5_5iA.js +0 -1
- package/dist/packem_shared/copySync-DffsYlhb.js +0 -1
- package/dist/packem_shared/emptyDir-BlBeczk0.js +0 -1
- package/dist/packem_shared/emptyDirSync-DfUZ9Ejz.js +0 -1
- package/dist/packem_shared/ensureDir-BEiomfxz.js +0 -1
- package/dist/packem_shared/ensureFileSync-CG07zjV7.js +0 -1
- package/dist/packem_shared/ensureLink-Dz-PDWa5.js +0 -1
- package/dist/packem_shared/ensureLinkSync-BZH7TaSQ.js +0 -1
- package/dist/packem_shared/ensureSymlink-Byi6ajoE.js +0 -1
- package/dist/packem_shared/ensureSymlinkSync-D7OCsAd8.js +0 -1
- package/dist/packem_shared/findUp-BHCEMf5y.js +0 -1
- package/dist/packem_shared/findUpSync-BKJsHMQN.js +0 -1
- package/dist/packem_shared/glob-BUjyjdE8.js +0 -1
- package/dist/packem_shared/glob-sync.d-0UK6O_wZ.d.ts +0 -54
- package/dist/packem_shared/globSync-Bk9TUV7x.js +0 -1
- package/dist/packem_shared/index-B2MhYg3r.js +0 -1
- package/dist/packem_shared/index-BHy3Kcr7.js +0 -11
- package/dist/packem_shared/index-CPZbuHkp.js +0 -1
- package/dist/packem_shared/index-LUKYN3u3.js +0 -1
- package/dist/packem_shared/indexToLineColumn-BfkIsWHQ-DQJmePiQ.js +0 -6
- package/dist/packem_shared/ini-preserve-D1DopDLd.js +0 -4
- package/dist/packem_shared/is-stats-identical-l1GRN4Qu.js +0 -1
- package/dist/packem_shared/isAccessible-B7guOm3k.js +0 -1
- package/dist/packem_shared/isAccessibleSync-XH4YleJW.js +0 -1
- package/dist/packem_shared/jsonc-merge-Bkw73TLW.js +0 -2
- package/dist/packem_shared/map-read-error-CR3rQUxx.js +0 -1
- package/dist/packem_shared/move-KhPRvsRd.js +0 -1
- package/dist/packem_shared/parseJson-lm3MUNdf.js +0 -1
- package/dist/packem_shared/readFile-VgxUDrNH.js +0 -1
- package/dist/packem_shared/readFileSync-CloFeQw8.js +0 -1
- package/dist/packem_shared/readIni-CEXHWn92.js +0 -1
- package/dist/packem_shared/readIniSync-DsxVHypc.js +0 -1
- package/dist/packem_shared/readJson-DV2KxaEJ.js +0 -1
- package/dist/packem_shared/readJson5-S68aVros.js +0 -1
- package/dist/packem_shared/readJson5Sync-Bi9Rv46R.js +0 -1
- package/dist/packem_shared/readJsonSync-DweZd5ZA.js +0 -1
- package/dist/packem_shared/readJsonc-Dqh-elUt.js +0 -1
- package/dist/packem_shared/readJsoncSync-Dy2PZG5g.js +0 -1
- package/dist/packem_shared/readToml-CN_xnICv.js +0 -1
- package/dist/packem_shared/readTomlSync-B9TVGzen.js +0 -1
- package/dist/packem_shared/readYaml-DcpUq11D.js +0 -1
- package/dist/packem_shared/readYamlSync-D5RVZwco.js +0 -1
- package/dist/packem_shared/remove-D_CUIlBL.js +0 -1
- package/dist/packem_shared/removeSync-F4nKiwrU.js +0 -1
- package/dist/packem_shared/resolve-symlink-target-CWrn0v4P.js +0 -1
- package/dist/packem_shared/sanitize-aEqeyx4d.js +0 -1
- package/dist/packem_shared/stripJsonComments-Bfcn2PKv.js +0 -1
- package/dist/packem_shared/to-uint-8-array-7sXMoZwU.js +0 -1
- package/dist/packem_shared/types.d-C-RhhzcS.d.ts +0 -1753
- package/dist/packem_shared/walk-B211aFS7.js +0 -1
- package/dist/packem_shared/walk-include-2NQzWTCI.js +0 -1
- package/dist/packem_shared/walkSync-VeMvHYLk.js +0 -1
- package/dist/packem_shared/writeFile-Dnba9aVe.js +0 -1
- package/dist/packem_shared/writeFileSync-pW8o2DG1.js +0 -1
- package/dist/packem_shared/writeIni-DgZ-0EUD.js +0 -4
- package/dist/packem_shared/writeIniSync-Buz4Cove.js +0 -4
- package/dist/packem_shared/writeJson-vexC7dw2.js +0 -4
- package/dist/packem_shared/writeJson5-DeW_smOs.js +0 -4
- package/dist/packem_shared/writeJson5Sync-Cz5pwaPh.js +0 -4
- package/dist/packem_shared/writeJsonSync-DJLfN5iT.js +0 -4
- package/dist/packem_shared/writeJsonc-BqJQS0Mk.js +0 -4
- package/dist/packem_shared/writeJsoncSync-CchlR2KW.js +0 -4
- package/dist/packem_shared/writeToml-Bn-wQdaM.js +0 -1
- package/dist/packem_shared/writeTomlSync-CTv4RXkJ.js +0 -1
- package/dist/packem_shared/writeYaml-BbiKaW3J.js +0 -1
- package/dist/packem_shared/writeYamlSync-dI80QfIA.js +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,13 @@
|
|
|
1
|
+
## @visulima/fs [6.0.1](https://github.com/visulima/visulima/compare/%40visulima%2Ffs%406.0.0...%40visulima%2Ffs%406.0.1) (2026-08-17)
|
|
2
|
+
|
|
3
|
+
## @visulima/fs [6.0.0](https://github.com/visulima/visulima/compare/%40visulima%2Ffs%405.1.0...%40visulima%2Ffs%406.0.0) (2026-08-08)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Dependencies
|
|
7
|
+
|
|
8
|
+
* **@visulima/path:** upgraded to 4.0.0
|
|
9
|
+
* **@visulima/yaml:** upgraded to 1.0.0
|
|
10
|
+
|
|
1
11
|
## @visulima/fs [5.1.0](https://github.com/visulima/visulima/compare/%40visulima%2Ffs%405.0.11...%40visulima%2Ffs%405.1.0) (2026-08-02)
|
|
2
12
|
|
|
3
13
|
|
package/LICENSE.md
CHANGED
|
@@ -312,9 +312,41 @@ Repository: git+https://github.com/SuperchupuDev/tinyglobby.git
|
|
|
312
312
|
|
|
313
313
|
# Licenses of bundled types
|
|
314
314
|
The published @visulima/fs artifact additionally contains code with the following licenses:
|
|
315
|
-
|
|
315
|
+
MIT, (MIT OR CC0-1.0)
|
|
316
316
|
|
|
317
317
|
# Bundled types:
|
|
318
|
+
## @visulima/yaml
|
|
319
|
+
License: MIT
|
|
320
|
+
By: Daniel Bannert
|
|
321
|
+
Repository: git+https://github.com/visulima/visulima.git
|
|
322
|
+
|
|
323
|
+
> MIT License
|
|
324
|
+
>
|
|
325
|
+
> Copyright (c) 2026 visulima
|
|
326
|
+
>
|
|
327
|
+
> Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
328
|
+
> of this software and associated documentation files (the "Software"), to deal
|
|
329
|
+
> in the Software without restriction, including without limitation the rights
|
|
330
|
+
> to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
331
|
+
> copies of the Software, and to permit persons to whom the Software is
|
|
332
|
+
> furnished to do so, subject to the following conditions:
|
|
333
|
+
>
|
|
334
|
+
> The above copyright notice and this permission notice shall be included in all
|
|
335
|
+
> copies or substantial portions of the Software.
|
|
336
|
+
>
|
|
337
|
+
> THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
338
|
+
> IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
339
|
+
> FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
340
|
+
> AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
341
|
+
> LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
342
|
+
> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
343
|
+
> SOFTWARE.
|
|
344
|
+
>
|
|
345
|
+
> <!-- DEPENDENCIES -->
|
|
346
|
+
> <!-- /DEPENDENCIES -->
|
|
347
|
+
|
|
348
|
+
---------------------------------------
|
|
349
|
+
|
|
318
350
|
## is-fs-case-sensitive
|
|
319
351
|
License: MIT
|
|
320
352
|
By: Hiroki Osame
|
|
@@ -373,23 +405,131 @@ Repository: git+https://github.com/SuperchupuDev/tinyglobby.git
|
|
|
373
405
|
|
|
374
406
|
---------------------------------------
|
|
375
407
|
|
|
376
|
-
##
|
|
377
|
-
License:
|
|
378
|
-
By:
|
|
379
|
-
Repository:
|
|
380
|
-
|
|
381
|
-
>
|
|
382
|
-
>
|
|
383
|
-
>
|
|
384
|
-
>
|
|
385
|
-
>
|
|
386
|
-
>
|
|
387
|
-
>
|
|
388
|
-
>
|
|
389
|
-
>
|
|
390
|
-
>
|
|
391
|
-
> OF
|
|
392
|
-
>
|
|
393
|
-
>
|
|
408
|
+
## type-fest
|
|
409
|
+
License: (MIT OR CC0-1.0)
|
|
410
|
+
By: Sindre Sorhus
|
|
411
|
+
Repository: sindresorhus/type-fest
|
|
412
|
+
|
|
413
|
+
> Creative Commons Legal Code
|
|
414
|
+
>
|
|
415
|
+
> CC0 1.0 Universal
|
|
416
|
+
>
|
|
417
|
+
> CREATIVE COMMONS CORPORATION IS NOT A LAW FIRM AND DOES NOT PROVIDE
|
|
418
|
+
> LEGAL SERVICES. DISTRIBUTION OF THIS DOCUMENT DOES NOT CREATE AN
|
|
419
|
+
> ATTORNEY-CLIENT RELATIONSHIP. CREATIVE COMMONS PROVIDES THIS
|
|
420
|
+
> INFORMATION ON AN "AS-IS" BASIS. CREATIVE COMMONS MAKES NO WARRANTIES
|
|
421
|
+
> REGARDING THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS
|
|
422
|
+
> PROVIDED HEREUNDER, AND DISCLAIMS LIABILITY FOR DAMAGES RESULTING FROM
|
|
423
|
+
> THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS PROVIDED
|
|
424
|
+
> HEREUNDER.
|
|
425
|
+
>
|
|
426
|
+
> Statement of Purpose
|
|
427
|
+
>
|
|
428
|
+
> The laws of most jurisdictions throughout the world automatically confer
|
|
429
|
+
> exclusive Copyright and Related Rights (defined below) upon the creator
|
|
430
|
+
> and subsequent owner(s) (each and all, an "owner") of an original work of
|
|
431
|
+
> authorship and/or a database (each, a "Work").
|
|
432
|
+
>
|
|
433
|
+
> Certain owners wish to permanently relinquish those rights to a Work for
|
|
434
|
+
> the purpose of contributing to a commons of creative, cultural and
|
|
435
|
+
> scientific works ("Commons") that the public can reliably and without fear
|
|
436
|
+
> of later claims of infringement build upon, modify, incorporate in other
|
|
437
|
+
> works, reuse and redistribute as freely as possible in any form whatsoever
|
|
438
|
+
> and for any purposes, including without limitation commercial purposes.
|
|
439
|
+
> These owners may contribute to the Commons to promote the ideal of a free
|
|
440
|
+
> culture and the further production of creative, cultural and scientific
|
|
441
|
+
> works, or to gain reputation or greater distribution for their Work in
|
|
442
|
+
> part through the use and efforts of others.
|
|
443
|
+
>
|
|
444
|
+
> For these and/or other purposes and motivations, and without any
|
|
445
|
+
> expectation of additional consideration or compensation, the person
|
|
446
|
+
> associating CC0 with a Work (the "Affirmer"), to the extent that he or she
|
|
447
|
+
> is an owner of Copyright and Related Rights in the Work, voluntarily
|
|
448
|
+
> elects to apply CC0 to the Work and publicly distribute the Work under its
|
|
449
|
+
> terms, with knowledge of his or her Copyright and Related Rights in the
|
|
450
|
+
> Work and the meaning and intended legal effect of CC0 on those rights.
|
|
451
|
+
>
|
|
452
|
+
> 1. Copyright and Related Rights. A Work made available under CC0 may be
|
|
453
|
+
> protected by copyright and related or neighboring rights ("Copyright and
|
|
454
|
+
> Related Rights"). Copyright and Related Rights include, but are not
|
|
455
|
+
> limited to, the following:
|
|
456
|
+
>
|
|
457
|
+
> i. the right to reproduce, adapt, distribute, perform, display,
|
|
458
|
+
> communicate, and translate a Work;
|
|
459
|
+
> ii. moral rights retained by the original author(s) and/or performer(s);
|
|
460
|
+
> iii. publicity and privacy rights pertaining to a person's image or
|
|
461
|
+
> likeness depicted in a Work;
|
|
462
|
+
> iv. rights protecting against unfair competition in regards to a Work,
|
|
463
|
+
> subject to the limitations in paragraph 4(a), below;
|
|
464
|
+
> v. rights protecting the extraction, dissemination, use and reuse of data
|
|
465
|
+
> in a Work;
|
|
466
|
+
> vi. database rights (such as those arising under Directive 96/9/EC of the
|
|
467
|
+
> European Parliament and of the Council of 11 March 1996 on the legal
|
|
468
|
+
> protection of databases, and under any national implementation
|
|
469
|
+
> thereof, including any amended or successor version of such
|
|
470
|
+
> directive); and
|
|
471
|
+
> vii. other similar, equivalent or corresponding rights throughout the
|
|
472
|
+
> world based on applicable law or treaty, and any national
|
|
473
|
+
> implementations thereof.
|
|
474
|
+
>
|
|
475
|
+
> 2. Waiver. To the greatest extent permitted by, but not in contravention
|
|
476
|
+
> of, applicable law, Affirmer hereby overtly, fully, permanently,
|
|
477
|
+
> irrevocably and unconditionally waives, abandons, and surrenders all of
|
|
478
|
+
> Affirmer's Copyright and Related Rights and associated claims and causes
|
|
479
|
+
> of action, whether now known or unknown (including existing as well as
|
|
480
|
+
> future claims and causes of action), in the Work (i) in all territories
|
|
481
|
+
> worldwide, (ii) for the maximum duration provided by applicable law or
|
|
482
|
+
> treaty (including future time extensions), (iii) in any current or future
|
|
483
|
+
> medium and for any number of copies, and (iv) for any purpose whatsoever,
|
|
484
|
+
> including without limitation commercial, advertising or promotional
|
|
485
|
+
> purposes (the "Waiver"). Affirmer makes the Waiver for the benefit of each
|
|
486
|
+
> member of the public at large and to the detriment of Affirmer's heirs and
|
|
487
|
+
> successors, fully intending that such Waiver shall not be subject to
|
|
488
|
+
> revocation, rescission, cancellation, termination, or any other legal or
|
|
489
|
+
> equitable action to disrupt the quiet enjoyment of the Work by the public
|
|
490
|
+
> as contemplated by Affirmer's express Statement of Purpose.
|
|
491
|
+
>
|
|
492
|
+
> 3. Public License Fallback. Should any part of the Waiver for any reason
|
|
493
|
+
> be judged legally invalid or ineffective under applicable law, then the
|
|
494
|
+
> Waiver shall be preserved to the maximum extent permitted taking into
|
|
495
|
+
> account Affirmer's express Statement of Purpose. In addition, to the
|
|
496
|
+
> extent the Waiver is so judged Affirmer hereby grants to each affected
|
|
497
|
+
> person a royalty-free, non transferable, non sublicensable, non exclusive,
|
|
498
|
+
> irrevocable and unconditional license to exercise Affirmer's Copyright and
|
|
499
|
+
> Related Rights in the Work (i) in all territories worldwide, (ii) for the
|
|
500
|
+
> maximum duration provided by applicable law or treaty (including future
|
|
501
|
+
> time extensions), (iii) in any current or future medium and for any number
|
|
502
|
+
> of copies, and (iv) for any purpose whatsoever, including without
|
|
503
|
+
> limitation commercial, advertising or promotional purposes (the
|
|
504
|
+
> "License"). The License shall be deemed effective as of the date CC0 was
|
|
505
|
+
> applied by Affirmer to the Work. Should any part of the License for any
|
|
506
|
+
> reason be judged legally invalid or ineffective under applicable law, such
|
|
507
|
+
> partial invalidity or ineffectiveness shall not invalidate the remainder
|
|
508
|
+
> of the License, and in such case Affirmer hereby affirms that he or she
|
|
509
|
+
> will not (i) exercise any of his or her remaining Copyright and Related
|
|
510
|
+
> Rights in the Work or (ii) assert any associated claims and causes of
|
|
511
|
+
> action with respect to the Work, in either case contrary to Affirmer's
|
|
512
|
+
> express Statement of Purpose.
|
|
513
|
+
>
|
|
514
|
+
> 4. Limitations and Disclaimers.
|
|
515
|
+
>
|
|
516
|
+
> a. No trademark or patent rights held by Affirmer are waived, abandoned,
|
|
517
|
+
> surrendered, licensed or otherwise affected by this document.
|
|
518
|
+
> b. Affirmer offers the Work as-is and makes no representations or
|
|
519
|
+
> warranties of any kind concerning the Work, express, implied,
|
|
520
|
+
> statutory or otherwise, including without limitation warranties of
|
|
521
|
+
> title, merchantability, fitness for a particular purpose, non
|
|
522
|
+
> infringement, or the absence of latent or other defects, accuracy, or
|
|
523
|
+
> the present or absence of errors, whether or not discoverable, all to
|
|
524
|
+
> the greatest extent permissible under applicable law.
|
|
525
|
+
> c. Affirmer disclaims responsibility for clearing rights of other persons
|
|
526
|
+
> that may apply to the Work or any use thereof, including without
|
|
527
|
+
> limitation any person's Copyright and Related Rights in the Work.
|
|
528
|
+
> Further, Affirmer disclaims responsibility for obtaining any necessary
|
|
529
|
+
> consents, permissions or other rights required for any use of the
|
|
530
|
+
> Work.
|
|
531
|
+
> d. Affirmer understands and acknowledges that Creative Commons is not a
|
|
532
|
+
> party to this document and has no duty or obligation with respect to
|
|
533
|
+
> this CC0 or use of the Work.
|
|
394
534
|
|
|
395
535
|
<!-- /TYPE_DEPENDENCIES -->
|
package/README.md
CHANGED
|
@@ -48,28 +48,28 @@ yarn add @visulima/fs
|
|
|
48
48
|
pnpm add @visulima/fs
|
|
49
49
|
```
|
|
50
50
|
|
|
51
|
-
> **Note:** If you want to parse or write YAML, you'll need to install
|
|
51
|
+
> **Note:** If you want to parse or write YAML, you'll need to install `@visulima/yaml` as well.
|
|
52
52
|
|
|
53
53
|
```sh
|
|
54
|
-
npm install yaml
|
|
54
|
+
npm install @visulima/yaml
|
|
55
55
|
```
|
|
56
56
|
|
|
57
57
|
```sh
|
|
58
|
-
yarn add yaml
|
|
58
|
+
yarn add @visulima/yaml
|
|
59
59
|
```
|
|
60
60
|
|
|
61
61
|
```sh
|
|
62
|
-
pnpm add yaml
|
|
62
|
+
pnpm add @visulima/yaml
|
|
63
63
|
```
|
|
64
64
|
|
|
65
|
-
> After installing
|
|
65
|
+
> After installing `@visulima/yaml`, you can use the `readYaml`, `readYamlSync` and `writeYaml`, `writeYamlSync` functions from `@visulima/fs/yaml`.
|
|
66
66
|
|
|
67
67
|
## Usage
|
|
68
68
|
|
|
69
69
|
### Quickstart by subpath
|
|
70
70
|
|
|
71
71
|
`@visulima/fs` ships one entry per concern. Import from the narrowest subpath you
|
|
72
|
-
need so the optional parser peers (
|
|
72
|
+
need so the optional parser peers (`@visulima/yaml`, `smol-toml`, `jsonc-parser`, `json5`,
|
|
73
73
|
`ini`) stay tree-shaken.
|
|
74
74
|
|
|
75
75
|
```typescript
|
package/dist/eol.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{createRequire as
|
|
2
|
-
`,
|
|
3
|
-
`,
|
|
1
|
+
import{createRequire as f}from"node:module";const i=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,{platform:a}=i,s=/\r?\n/g,n=`
|
|
2
|
+
`,c=`\r
|
|
3
|
+
`,u=a==="win32"?c:n,p=t=>{const e=t.match(s);if(!e||e.length===0)return null;const r=e.filter(l=>l===c).length,o=e.length-r;return r>o?c:n},g=(t,e)=>t.replaceAll(s,e);export{c as CRLF,u as EOL,n as LF,p as detect,g as format};
|
package/dist/glob-parent.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createRequire as
|
|
1
|
+
import{createRequire as m}from"node:module";import{g as h}from"./packem_shared/_commonjsHelpers-CqkleIqs.js";import{r as q}from"./packem_shared/index-ovH_d7Hf.js";let v;const _=a=>(v??=m(import.meta.url))(a),o=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,f=a=>{if(typeof o<"u"&&o.versions&&o.versions.node){const[n,s]=o.versions.node.split(".").map(Number);if(n>22||n===22&&s>=3||n===20&&s>=16)return o.getBuiltinModule(a)}return _(a)},P=f("path"),j=f("os");var l,c;function x(){if(c)return l;c=1;var a=q(),n=P.posix.dirname,s=j.platform()==="win32",t="/",p=/\\/g,d=/\\([!*?|[\](){}])/g;l=function(e,i){var u=Object.assign({flipBackslashes:!0},i);u.flipBackslashes&&s&&e.indexOf(t)<0&&(e=e.replace(p,t)),b(e)&&(e+=t),e+="a";do e=n(e);while(g(e));return e.replace(d,"$1")};function b(r){var e=r.slice(-1),i;switch(e){case"}":i="{";break;case"]":i="[";break;default:return!1}var u=r.indexOf(i);return u<0?!1:r.slice(u+1,-1).includes(t)}function g(r){return/\([^()]+$/.test(r)||r[0]==="{"||r[0]==="["||/[^\\][{[]/.test(r)?!0:a(r)}return l}var $=x();const k=h($),R=(a,n)=>k(a,n);export{R as default};
|
package/dist/glob.d.ts
CHANGED
|
@@ -1,4 +1,56 @@
|
|
|
1
|
-
|
|
2
|
-
export type { G as GlobOptions } from "./packem_shared/types.d-C-RhhzcS.js";
|
|
1
|
+
import { H as GlobOptions } from "./packem_shared/types.d-B-T1rDxl.js";
|
|
3
2
|
import 'node:fs';
|
|
4
3
|
import 'fdir';
|
|
4
|
+
/**
|
|
5
|
+
* Asynchronously matches files on disk using one or more glob patterns.
|
|
6
|
+
*
|
|
7
|
+
* Powered by [`tinyglobby`](https://github.com/SuperchupuDev/tinyglobby); `tinyglobby` is bundled into the
|
|
8
|
+
* built output so it does not appear as a runtime dependency of `@visulima/fs`.
|
|
9
|
+
*
|
|
10
|
+
* Pattern forms:
|
|
11
|
+
*
|
|
12
|
+
* - Plain glob — `src/**\/*.ts`
|
|
13
|
+
* - Negated pattern — `!src/**\/*.spec.ts` inside `patterns` adds to the internal ignore list (same as passing it via `ignore`).
|
|
14
|
+
* - Negated ignore — a leading `!` inside {@link GlobOptions.ignore} _un-ignores_ entries that an earlier ignore pattern would drop, e.g. `ignore: ["dist/**", "!dist/index.d.ts"]`.
|
|
15
|
+
* @param patterns A single glob pattern or an array of glob patterns.
|
|
16
|
+
* @param options Optional glob options. See {@link GlobOptions}.
|
|
17
|
+
* @returns A promise resolving to the array of matched paths. Paths are relative to {@link GlobOptions.cwd} unless {@link GlobOptions.absolute} is `true`.
|
|
18
|
+
* @example
|
|
19
|
+
* ```javascript
|
|
20
|
+
* import { glob } from "@visulima/fs";
|
|
21
|
+
*
|
|
22
|
+
* const jsFiles = await glob("src/**\/*.{js,ts}", { cwd: process.cwd(), ignore: ["**\/node_modules/**"] });
|
|
23
|
+
* console.log(jsFiles);
|
|
24
|
+
*
|
|
25
|
+
* // Negated ignore: drop everything under `ignored/` except `ignored/keep.ts`.
|
|
26
|
+
* const keep = await glob("**\/*.ts", { ignore: ["ignored/**", "!ignored/keep.ts"] });
|
|
27
|
+
* ```
|
|
28
|
+
*/
|
|
29
|
+
declare const glob: (patterns: string | ReadonlyArray<string>, options?: GlobOptions) => Promise<string[]>;
|
|
30
|
+
/**
|
|
31
|
+
* Synchronously matches files on disk using one or more glob patterns.
|
|
32
|
+
*
|
|
33
|
+
* Synchronous counterpart of `glob`. Powered by [`tinyglobby`](https://github.com/SuperchupuDev/tinyglobby);
|
|
34
|
+
* bundled into the built output so it does not appear as a runtime dependency of `@visulima/fs`.
|
|
35
|
+
*
|
|
36
|
+
* Pattern forms:
|
|
37
|
+
*
|
|
38
|
+
* - Plain glob — `src/**\/*.ts`
|
|
39
|
+
* - Negated pattern — `!src/**\/*.spec.ts` inside `patterns` adds to the internal ignore list.
|
|
40
|
+
* - Negated ignore — a leading `!` inside {@link GlobOptions.ignore} _un-ignores_ entries that an earlier ignore pattern would drop, e.g. `ignore: ["dist/**", "!dist/index.d.ts"]`.
|
|
41
|
+
* @param patterns A single glob pattern or an array of glob patterns.
|
|
42
|
+
* @param options Optional glob options. See {@link GlobOptions}.
|
|
43
|
+
* @returns The array of matched paths. Paths are relative to {@link GlobOptions.cwd} unless {@link GlobOptions.absolute} is `true`.
|
|
44
|
+
* @example
|
|
45
|
+
* ```javascript
|
|
46
|
+
* import { globSync } from "@visulima/fs";
|
|
47
|
+
*
|
|
48
|
+
* const jsFiles = globSync(["src/**\/*.ts", "!**\/*.spec.ts"]);
|
|
49
|
+
* console.log(jsFiles);
|
|
50
|
+
*
|
|
51
|
+
* // Negated ignore: drop everything under `ignored/` except `ignored/keep.ts`.
|
|
52
|
+
* const keep = globSync("**\/*.ts", { ignore: ["ignored/**", "!ignored/keep.ts"] });
|
|
53
|
+
* ```
|
|
54
|
+
*/
|
|
55
|
+
declare const globSync: (patterns: string | ReadonlyArray<string>, options?: GlobOptions) => string[];
|
|
56
|
+
export { type GlobOptions, glob, globSync };
|
package/dist/glob.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{default as e}from"./packem_shared/glob-
|
|
1
|
+
import{default as e}from"./packem_shared/glob-Cyk1H9ZL.js";import{default as l}from"./packem_shared/globSync-Cm0u7eCn.js";export{e as glob,l as globSync};
|
package/dist/index.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { q as WalkOptions, F as FindUpName, r as FindUpOptions, s as FindUpNameSync, t as WalkEntry, u as ReadFileOptions, v as ContentType, w as ReadJsonOptions, l as JsonReviver, x as RetryOptions, y as WriteFileOptions, z as WriteJsonOptions } from "./packem_shared/types.d-
|
|
2
|
-
export { type A as CodeFrameLocation, type k as CodeFrameOptions, B as FIND_UP_STOP, D as F_OK, type E as FindUpNameFnResult, type
|
|
1
|
+
import { q as WalkOptions, F as FindUpName, r as FindUpOptions, s as FindUpNameSync, t as WalkEntry, u as ReadFileOptions, v as ContentType, w as ReadJsonOptions, l as JsonReviver, x as RetryOptions, y as WriteFileOptions, z as WriteJsonOptions } from "./packem_shared/types.d-B-T1rDxl.js";
|
|
2
|
+
export { type A as CodeFrameLocation, type k as CodeFrameOptions, B as FIND_UP_STOP, D as F_OK, type E as FindUpNameFnResult, type G as FindUpNameSyncFnResult, type H as GlobOptions, type o as JsonReplacer, K as R_OK, type L as ReadFileEncoding, M as W_OK, X as X_OK } from "./packem_shared/types.d-B-T1rDxl.js";
|
|
3
3
|
import { symlink } from 'node:fs';
|
|
4
4
|
export { CRLF, EOL, LF, detect, format } from "./eol.js";
|
|
5
|
-
export {
|
|
5
|
+
export { glob, globSync } from "./glob.js";
|
|
6
6
|
export { type GlobParentOptions, default as globParent } from "./glob-parent.js";
|
|
7
7
|
export { type IsGlobOptions, default as isGlob } from "./is-glob.js";
|
|
8
8
|
export { type MatchOptions, match, matcher } from "./match.js";
|
|
9
|
-
import { JsonValue } from
|
|
9
|
+
import { J as JsonValue } from "./packem_shared/json-value.d-DZqAihX4.js";
|
|
10
10
|
import fs from 'fs';
|
|
11
11
|
import 'fdir';
|
|
12
12
|
/**
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createRequire as h}from"node:module";import{FIND_UP_STOP as R,F_OK as P,R_OK as $,W_OK as J,X_OK as K}from"./packem_shared/FIND_UP_STOP-
|
|
1
|
+
import{createRequire as h}from"node:module";import{FIND_UP_STOP as R,F_OK as P,R_OK as $,W_OK as J,X_OK as K}from"./packem_shared/FIND_UP_STOP-pQqZdUPw.js";import{default as U}from"./packem_shared/copy-Cv8Vvdrc.js";import{default as M}from"./packem_shared/copySync-JIxmcGrd.js";import{default as B}from"./packem_shared/ensureDir-qy_X-WeG.js";import{default as N}from"./packem_shared/ensureDirSync-ONFJBCbg.js";import{default as G}from"./packem_shared/ensureFile-q1ozF6q5.js";import{default as X}from"./packem_shared/ensureFileSync-B6eR38N_.js";import{default as Q}from"./packem_shared/ensureLink-BpsTVGAm.js";import{default as Y}from"./packem_shared/ensureLinkSync-B5moWvh3.js";import{default as ee}from"./packem_shared/ensureSymlink-BF0BwVPy.js";import{default as te}from"./packem_shared/ensureSymlinkSync-D-JzDuD7.js";import{CRLF as se,EOL as ae,LF as ne,detect as fe,format as ie}from"./eol.js";import{default as le}from"./packem_shared/collect-DXVMgRiZ.js";import{default as pe}from"./packem_shared/collectSync-jjcJdHox.js";import{default as de}from"./packem_shared/findUp-BlQ1EUhu.js";import{default as ye}from"./packem_shared/findUpSync-CF1OXVQw.js";import{default as ve}from"./packem_shared/glob-Cyk1H9ZL.js";import{default as he}from"./packem_shared/globSync-Cm0u7eCn.js";import{default as be}from"./packem_shared/walk-Brue5N30.js";import{default as we}from"./packem_shared/walkSync-BWGgTwUy.js";import{default as Ce}from"./glob-parent.js";import{default as je}from"./packem_shared/isAccessible-CqNOFdZu.js";import{default as Oe}from"./packem_shared/isAccessibleSync-DYKTrrvc.js";import{default as Re}from"./is-glob.js";import{match as $e,matcher as Je}from"./match.js";import{move as Te,moveSync as Ue,rename as We,renameSync as Me}from"./packem_shared/move-DG3P4i6Y.js";import{default as Be}from"./packem_shared/readFile-DbKGLwIK.js";import{default as Ne}from"./packem_shared/readFileSync-CTTHkZ_p.js";import{default as Ge}from"./packem_shared/readJson-CClJlGok.js";import{default as Xe}from"./packem_shared/readJsonSync-CbryXYxN.js";import{default as Qe}from"./packem_shared/emptyDir-DQ1LfO2i.js";import{default as Ye}from"./packem_shared/emptyDirSync-BXDqirP1.js";import{default as er}from"./packem_shared/remove-4ofpEuH1.js";import{default as tr}from"./packem_shared/removeSync-g1D5kONg.js";import{sanitize as sr}from"./packem_shared/sanitize-B1LHjdjC.js";import{default as nr}from"./packem_shared/writeFile-BIBP7wbK.js";import{default as ir}from"./packem_shared/writeFileSync-DJoHk3Ks.js";import{default as lr}from"./packem_shared/writeJson-DmN1UqZc.js";import{default as pr}from"./packem_shared/writeJsonSync-BiFyXQ5h.js";let F;const b=n=>(F??=h(import.meta.url))(n),f=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,u=n=>{if(typeof f<"u"&&f.versions&&f.versions.node){const[s,i]=f.versions.node.split(".").map(Number);if(s>22||s===22&&i>=3||s===20&&i>=16)return f.getBuiltinModule(n)}return b(n)},g=u("fs"),w=u("os"),k=u("path");var l={},x;function C(){if(x)return l;x=1;var n=Object.defineProperty,s=(o,e)=>n(o,"name",{value:e,configurable:!0}),i=g,y=w,S=k;const p=s(o=>{let e="";for(let r=0;r<o.length;r+=1){const t=o[r],a=t.toUpperCase();e+=t===a?t.toLowerCase():a}return e},"invertCase"),c=new Map,m=s((o,e)=>{const r=S.join(o,`.is-fs-case-sensitive-test-${process.pid}`);try{return e.writeFileSync(r,""),!e.existsSync(p(r))}finally{try{e.unlinkSync(r)}catch{}}},"checkDirectoryCaseWithWrite"),v=s((o,e,r)=>{try{return m(o,r)}catch(t){if(e===void 0)return m(y.tmpdir(),r);throw t}},"checkDirectoryCaseWithFallback"),_=s((o,e=i,r=!0)=>{const t=o??process.cwd();if(r&&c.has(t))return c.get(t);let a;const d=p(t);return d!==t&&e.existsSync(t)?a=!e.existsSync(d):a=v(t,o,e),r&&c.set(t,a),a},"isFsCaseSensitive");return l.isFsCaseSensitive=_,l}var D=C();const q=D.isFsCaseSensitive;export{se as CRLF,ae as EOL,R as FIND_UP_STOP,P as F_OK,ne as LF,$ as R_OK,J as W_OK,K as X_OK,le as collect,pe as collectSync,U as copy,M as copySync,fe as detect,Qe as emptyDir,Ye as emptyDirSync,B as ensureDir,N as ensureDirSync,G as ensureFile,X as ensureFileSync,Q as ensureLink,Y as ensureLinkSync,ee as ensureSymlink,te as ensureSymlinkSync,de as findUp,ye as findUpSync,ie as format,ve as glob,Ce as globParent,he as globSync,je as isAccessible,Oe as isAccessibleSync,q as isFsCaseSensitive,Re as isGlob,$e as match,Je as matcher,Te as move,Ue as moveSync,Be as readFile,Ne as readFileSync,Ge as readJson,Xe as readJsonSync,er as remove,tr as removeSync,We as rename,Me as renameSync,sr as sanitize,be as walk,we as walkSync,nr as writeFile,ir as writeFileSync,lr as writeJson,pr as writeJsonSync};
|
package/dist/ini.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CompressionType, R as ReadIniOptions, W as WriteIniOptions } from "./packem_shared/types.d-
|
|
2
|
-
export type { I as IniEncodeOptions, a as IniLineEnding } from "./packem_shared/types.d-
|
|
1
|
+
import { C as CompressionType, R as ReadIniOptions, W as WriteIniOptions } from "./packem_shared/types.d-B-T1rDxl.js";
|
|
2
|
+
export type { I as IniEncodeOptions, a as IniLineEnding } from "./packem_shared/types.d-B-T1rDxl.js";
|
|
3
3
|
import 'node:fs';
|
|
4
4
|
import 'fdir';
|
|
5
5
|
/**
|
package/dist/ini.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{default as a}from"./packem_shared/readIni-
|
|
1
|
+
import{default as a}from"./packem_shared/readIni-C9VUitQm.js";import{default as f}from"./packem_shared/readIniSync-DhMbhDPx.js";import{default as d}from"./packem_shared/writeIni--gog68qN.js";import{default as n}from"./packem_shared/writeIniSync-BL_z8aMQ.js";export{a as readIni,f as readIniSync,d as writeIni,n as writeIniSync};
|
package/dist/is-glob.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{g as s}from"./packem_shared/_commonjsHelpers-
|
|
1
|
+
import{g as s}from"./packem_shared/_commonjsHelpers-CqkleIqs.js";import{r as t}from"./packem_shared/index-ovH_d7Hf.js";var l=t();const a=s(l),m=(o,r)=>a(o,r);export{m as default};
|
package/dist/json5.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CompressionType, b as ReadJson5Options, J as Json5Reviver, c as WriteJson5Options } from "./packem_shared/types.d-
|
|
2
|
-
export type { d as Json5Replacer } from "./packem_shared/types.d-
|
|
1
|
+
import { C as CompressionType, b as ReadJson5Options, J as Json5Reviver, c as WriteJson5Options } from "./packem_shared/types.d-B-T1rDxl.js";
|
|
2
|
+
export type { d as Json5Replacer } from "./packem_shared/types.d-B-T1rDxl.js";
|
|
3
3
|
import 'node:fs';
|
|
4
4
|
import 'fdir';
|
|
5
5
|
declare function readJson5<R = unknown>(path: URL | string, options?: ReadJson5Options<CompressionType>): Promise<R>;
|
package/dist/json5.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{default as r}from"./packem_shared/readJson5-
|
|
1
|
+
import{default as r}from"./packem_shared/readJson5-D33tgtEU.js";import{default as t}from"./packem_shared/readJson5Sync-DEd-ejtp.js";import{default as s}from"./packem_shared/writeJson5-CPRmF2K7.js";import{default as n}from"./packem_shared/writeJson5Sync-BiUfm-cZ.js";export{r as readJson5,t as readJson5Sync,s as writeJson5,n as writeJson5Sync};
|
package/dist/jsonc.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CompressionType, e as ReadJsoncOptions, f as WriteJsoncOptions } from "./packem_shared/types.d-
|
|
2
|
-
export type { g as JsoncFormattingOptions, h as JsoncParseOptions } from "./packem_shared/types.d-
|
|
1
|
+
import { C as CompressionType, e as ReadJsoncOptions, f as WriteJsoncOptions } from "./packem_shared/types.d-B-T1rDxl.js";
|
|
2
|
+
export type { g as JsoncFormattingOptions, h as JsoncParseOptions } from "./packem_shared/types.d-B-T1rDxl.js";
|
|
3
3
|
import 'node:fs';
|
|
4
4
|
import 'fdir';
|
|
5
5
|
/**
|
package/dist/jsonc.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{default as r}from"./packem_shared/readJsonc-
|
|
1
|
+
import{default as r}from"./packem_shared/readJsonc-Cp1KzmVx.js";import{default as t}from"./packem_shared/readJsoncSync-sE30rJ5W.js";import{default as s}from"./packem_shared/writeJsonc-B4ahk9a2.js";import{default as d}from"./packem_shared/writeJsoncSync-lBv1IFDo.js";export{r as readJsonc,t as readJsoncSync,s as writeJsonc,d as writeJsoncSync};
|
package/dist/match.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{p as s}from"./packem_shared/index-DDkv7LRn.js";const i=(r,c,o)=>{const t=s(c,o);return Array.isArray(r)?r.some(n=>t(n)):t(r)},m=(r,c)=>{const o=s(r,c);return t=>o(t)};export{i as match,m as matcher};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const o=0,_=4,n=2,t=1,s=Symbol("findUpStop"),c=/"(?:[^"\\]|\\.)*"|\/\/[^\r\n]*|\/\*[\s\S]*?\*\//g;export{s as FIND_UP_STOP,o as F_OK,c as INTERNAL_STRIP_JSON_REGEX,_ as R_OK,n as W_OK,t as X_OK};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
function e(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}export{e as g};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const n=t=>{if(!t||!(t instanceof URL)&&typeof t!="string")throw new TypeError("Path must be a non-empty string or URL.")};export{n as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const t=e=>{const r={force:!0,recursive:!0};return e?.maxRetries!==void 0&&(r.maxRetries=e.maxRetries),e?.retryDelay!==void 0&&(r.retryDelay=e.retryDelay),r};export{t as b};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import a from"./walk-Brue5N30.js";const c=async(r,s={})=>{Array.isArray(s.extensions)||(s.extensions=["js","mjs","cjs","ts"]);const t=[];for await(const e of a(r,s))t.push(e.path);return t};export{c as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import n from"./walkSync-BWGgTwUy.js";const o=(t,s={})=>{Array.isArray(s.extensions)||(s.extensions=["js","mjs","cjs","ts"]);const r=[];for(const e of n(t,s))r.push(e.path);return r};export{o as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createRequire as h}from"node:module";import{toPath as n}from"@visulima/path/utils";import E from"./AlreadyExistsError-DEb3UWja.js";import c from"./assertValidFileOrDirectoryPath-CAHgg-jK.js";let y;const v=e=>(y??=h(import.meta.url))(e),t=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,g=e=>{if(typeof t<"u"&&t.versions&&t.versions.node){const[r,s]=t.versions.node.split(".").map(Number);if(r>22||r===22&&s>=3||r===20&&s>=16)return t.getBuiltinModule(e)}return v(e)},{cp:j}=g("node:fs/promises"),T=async(e,r,s={})=>{c(e),c(r);const{dereference:a=!1,errorOnExist:l=!0,filter:f,overwrite:p=!0,preserveTimestamps:u=!1,recursive:d=!0,verbatimSymlinks:m=!1}=s,_=n(e),o=n(r);try{await j(_,o,{dereference:a,errorOnExist:l,filter:f,force:p,preserveTimestamps:u,recursive:d,verbatimSymlinks:m})}catch(i){throw i?.code==="ERR_FS_CP_EEXIST"?new E(`destination already exists, copy '${o}'`):i}};export{T as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createRequire as y}from"node:module";import{toPath as n}from"@visulima/path/utils";import E from"./AlreadyExistsError-DEb3UWja.js";import c from"./assertValidFileOrDirectoryPath-CAHgg-jK.js";let h;const v=e=>(h??=y(import.meta.url))(e),t=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,g=e=>{if(typeof t<"u"&&t.versions&&t.versions.node){const[r,o]=t.versions.node.split(".").map(Number);if(r>22||r===22&&o>=3||r===20&&o>=16)return t.getBuiltinModule(e)}return v(e)},{cpSync:j}=g("node:fs"),T=(e,r,o={})=>{c(e),c(r);const{dereference:a=!1,errorOnExist:l=!0,filter:f,overwrite:u=!0,preserveTimestamps:p=!1,recursive:d=!0,verbatimSymlinks:_=!1}=o,m=n(e),s=n(r);try{j(m,s,{dereference:a,errorOnExist:l,filter:f,force:u,preserveTimestamps:p,recursive:d,verbatimSymlinks:_})}catch(i){throw i?.code==="ERR_FS_CP_EEXIST"?new E(`destination already exists, copy '${s}'`):i}};export{T as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createRequire as c}from"node:module";import{join as _}from"@visulima/path";import{toPath as d}from"@visulima/path/utils";import j from"./assertValidFileOrDirectoryPath-CAHgg-jK.js";import{b as y}from"./build-rm-options-_U1T9rOz.js";let a;const m=e=>(a??=c(import.meta.url))(e),t=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,s=e=>{if(typeof t<"u"&&t.versions&&t.versions.node){const[o,r]=t.versions.node.split(".").map(Number);if(o>22||o===22&&r>=3||o===20&&r>=16)return t.getBuiltinModule(e)}return m(e)},{existsSync:u}=s("node:fs"),{mkdir:f,readdir:p,rm:l}=s("node:fs/promises"),R=async(e,o)=>{if(j(e),!u(e)){await f(e,{recursive:!0});return}const r=await p(e),i=y(o);for(const n of r)await l(_(d(e),n),i)};export{R as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createRequire as i}from"node:module";import{join as l}from"@visulima/path";import{toPath as _}from"@visulima/path/utils";import d from"./assertValidFileOrDirectoryPath-CAHgg-jK.js";import{b as y}from"./build-rm-options-_U1T9rOz.js";let n;const c=e=>(n??=i(import.meta.url))(e),o=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,m=e=>{if(typeof o<"u"&&o.versions&&o.versions.node){const[r,t]=o.versions.node.split(".").map(Number);if(r>22||r===22&&t>=3||r===20&&t>=16)return o.getBuiltinModule(e)}return c(e)},{existsSync:u,mkdirSync:a,readdirSync:f,rmSync:p}=m("node:fs"),q=(e,r)=>{if(d(e),!u(e)){a(e,{recursive:!0});return}const t=y(r);for(const s of f(e))p(l(_(e),s),t)};export{q as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createRequire as n}from"node:module";import l from"./assertValidFileOrDirectoryPath-CAHgg-jK.js";import{g as i}from"./get-file-info-type-DzWpohDB.js";let c;const a=r=>(c??=n(import.meta.url))(r),s=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,u=r=>{if(typeof s<"u"&&s.versions&&s.versions.node){const[e,t]=s.versions.node.split(".").map(Number);if(e>22||e===22&&t>=3||e===20&&t>=16)return s.getBuiltinModule(r)}return a(r)},{lstat:o,mkdir:f}=u("node:fs/promises"),h=async r=>{l(r);try{const e=await o(r);if(!e.isDirectory())throw new Error(`Ensure path exists, expected 'dir', got '${String(i(e))}'`);return}catch(e){if(e.code!=="ENOENT")throw e}try{await f(r,{recursive:!0})}catch(e){if(e.code!=="EEXIST")throw e;const t=await o(r);if(!t.isDirectory())throw new Error(`Ensure path exists, expected 'dir', got '${String(i(t))}'`,{cause:e})}};export{h as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createRequire as n}from"node:module";import
|
|
1
|
+
import{createRequire as n}from"node:module";import l from"./assertValidFileOrDirectoryPath-CAHgg-jK.js";import{g as i}from"./get-file-info-type-DzWpohDB.js";let c;const u=r=>(c??=n(import.meta.url))(r),o=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,a=r=>{if(typeof o<"u"&&o.versions&&o.versions.node){const[e,t]=o.versions.node.split(".").map(Number);if(e>22||e===22&&t>=3||e===20&&t>=16)return o.getBuiltinModule(r)}return u(r)},{lstatSync:s,mkdirSync:f}=a("node:fs"),h=r=>{l(r);try{const e=s(r);if(!e.isDirectory())throw new Error(`Ensure path exists, expected 'dir', got '${String(i(e))}'`);return}catch(e){if(e.code!=="ENOENT")throw e}try{f(r,{recursive:!0})}catch(e){if(e.code!=="EEXIST")throw e;const t=s(r);if(!t.isDirectory())throw new Error(`Ensure path exists, expected 'dir', got '${String(i(t))}'`,{cause:e})}};export{h as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createRequire as
|
|
1
|
+
import{createRequire as s}from"node:module";import{dirname as u}from"@visulima/path";import{toPath as m}from"@visulima/path/utils";import l from"./assertValidFileOrDirectoryPath-CAHgg-jK.js";import f from"./ensureDir-qy_X-WeG.js";import{g as d}from"./get-file-info-type-DzWpohDB.js";let i;const n=e=>(i??=s(import.meta.url))(e),t=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,a=e=>{if(typeof t<"u"&&t.versions&&t.versions.node){const[r,o]=t.versions.node.split(".").map(Number);if(r>22||r===22&&o>=3||r===20&&o>=16)return t.getBuiltinModule(e)}return n(e)},{lstat:c,writeFile:p}=a("node:fs/promises"),F=async e=>{l(e);try{const r=await c(e);if(!r.isFile())throw new Error(`Ensure path exists, expected 'file', got '${String(d(r))}'`)}catch(r){if(r.code==="ENOENT"){await f(u(m(e))),await p(e,new Uint8Array);return}throw r}};export{F as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createRequire as s}from"node:module";import{dirname as p}from"@visulima/path";import{toPath as l}from"@visulima/path/utils";import m from"./assertValidFileOrDirectoryPath-CAHgg-jK.js";import f from"./ensureDirSync-ONFJBCbg.js";import{g as d}from"./get-file-info-type-DzWpohDB.js";let i;const n=e=>(i??=s(import.meta.url))(e),t=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,c=e=>{if(typeof t<"u"&&t.versions&&t.versions.node){const[r,o]=t.versions.node.split(".").map(Number);if(r>22||r===22&&o>=3||r===20&&o>=16)return t.getBuiltinModule(e)}return n(e)},{lstatSync:a,writeFileSync:u}=c("node:fs"),F=e=>{m(e);try{const r=a(e);if(!r.isFile())throw new Error(`Ensure path exists, expected 'file', got '${String(d(r))}'`)}catch(r){if(r.code==="ENOENT"){f(p(l(e))),u(e,new Uint8Array);return}throw r}};export{F as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createRequire as p}from"node:module";import{toNamespacedPath as n,dirname as h}from"@visulima/path";import{toPath as c}from"@visulima/path/utils";import l from"./assertValidFileOrDirectoryPath-CAHgg-jK.js";import g from"./ensureDir-qy_X-WeG.js";import{i as y}from"./is-stats-identical-DOh8_0KH.js";let f;const u=e=>(f??=p(import.meta.url))(e),s=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,_=e=>{if(typeof s<"u"&&s.versions&&s.versions.node){const[r,t]=s.versions.node.split(".").map(Number);if(r>22||r===22&&t>=3||r===20&&t>=16)return s.getBuiltinModule(e)}return u(e)},{lstat:i,link:d}=_("node:fs/promises"),v=async(e,r)=>{l(e),l(r),e=n(c(e)),r=n(c(r));let t;try{t=await i(r)}catch{}let a;try{a=await i(e)}catch(m){const o=m;throw o.message=o.message.replace("lstat","ensureLink"),o}t&&y(a,t)||(await g(h(r)),await d(e,r))};export{v as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createRequire as p}from"node:module";import{toNamespacedPath as c,dirname as h}from"@visulima/path";import{toPath as a}from"@visulima/path/utils";import l from"./assertValidFileOrDirectoryPath-CAHgg-jK.js";import y from"./ensureDirSync-ONFJBCbg.js";import{i as g}from"./is-stats-identical-DOh8_0KH.js";let f;const u=e=>(f??=p(import.meta.url))(e),s=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,_=e=>{if(typeof s<"u"&&s.versions&&s.versions.node){const[r,t]=s.versions.node.split(".").map(Number);if(r>22||r===22&&t>=3||r===20&&t>=16)return s.getBuiltinModule(e)}return u(e)},{lstatSync:n,linkSync:d}=_("node:fs"),v=(e,r)=>{l(e),l(r),e=c(a(e)),r=c(a(r));let t;try{t=n(r)}catch{}let i;try{i=n(e)}catch(m){const o=m;throw o.message=o.message.replace("lstat","ensureLink"),o}t&&g(i,t)||(y(h(r)),d(e,r))};export{v as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createRequire as S}from"node:module";import{toNamespacedPath as f,dirname as b,resolve as v}from"@visulima/path";import{toPath as m}from"@visulima/path/utils";import u from"./assertValidFileOrDirectoryPath-CAHgg-jK.js";import E from"./ensureDir-qy_X-WeG.js";import{g as y}from"./get-file-info-type-DzWpohDB.js";import{i as R}from"./is-stats-identical-DOh8_0KH.js";import{r as $}from"./resolve-symlink-target-D4Pb9Fjw.js";import h from"./AlreadyExistsError-DEb3UWja.js";let g;const P=e=>(g??=S(import.meta.url))(e),s=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,T=e=>{if(typeof s<"u"&&s.versions&&s.versions.node){const[t,r]=s.versions.node.split(".").map(Number);if(t>22||t===22&&r>=3||t===20&&r>=16)return s.getBuiltinModule(e)}return P(e)},{lstat:l,stat:d,symlink:j,readlink:I}=T("node:fs/promises"),q=process.platform==="win32"||/^(?:msys|cygwin)$/.test(process.env.OSTYPE),V=async(e,t,r)=>{u(e),u(t);const o=$(e,t);t=f(m(t));try{if((await l(t)).isSymbolicLink()){const[i,c]=await Promise.all([d(o),d(t)]);if(R(i,c))return}}catch{}const w=await l(o),_=y(w);await E(b(t));let a=r??"file";r||(q?a="junction":a=_==="dir"?"dir":"file");try{await j(f(m(o)),t,a)}catch(n){if(n.code!=="EEXIST")throw n;const i=await l(t);if(!i.isSymbolicLink())throw new h(`A ${String(y(i))} already exists at the path: ${t}`);const c=await I(t),p=f(v(c));if(p!==o)throw new h(`A symlink targeting to an undesired path already exists: ${t} -> ${p}`)}};export{V as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createRequire as P}from"node:module";import{toNamespacedPath as d,dirname as v,resolve as E}from"@visulima/path";import{toPath as y}from"@visulima/path/utils";import u from"./assertValidFileOrDirectoryPath-CAHgg-jK.js";import R from"./ensureDirSync-ONFJBCbg.js";import{g as m}from"./get-file-info-type-DzWpohDB.js";import{i as S}from"./is-stats-identical-DOh8_0KH.js";import{r as $}from"./resolve-symlink-target-D4Pb9Fjw.js";import h from"./AlreadyExistsError-DEb3UWja.js";let T;const w=r=>(T??=P(import.meta.url))(r),s=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,j=r=>{if(typeof s<"u"&&s.versions&&s.versions.node){const[t,e]=s.versions.node.split(".").map(Number);if(t>22||t===22&&e>=3||t===20&&e>=16)return s.getBuiltinModule(r)}return w(r)},{lstatSync:l,statSync:n,symlinkSync:I,readlinkSync:b}=j("node:fs"),q=process.platform==="win32"||/^(?:msys|cygwin)$/.test(process.env.OSTYPE),V=(r,t,e)=>{u(r),u(t);const o=$(r,t);t=d(y(t));try{if(l(t).isSymbolicLink()&&S(n(o),n(t))){const i=n(o),f=n(t);if(S(i,f))return}}catch{}const _=l(o),g=m(_);R(v(t));let c=e??"file";e||(q?c="junction":c=g==="dir"?"dir":"file");try{I(d(y(o)),t,c)}catch(a){if(a.code!=="EEXIST")throw a;const i=l(t);if(!i.isSymbolicLink())throw new h(`A ${String(m(i))} already exists at the path: ${t}`);const f=b(t),p=d(E(f));if(p!==o)throw new h(`A symlink targeting to an undesired path already exists: ${t} -> ${p}`)}};export{V as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createRequire as m}from"node:module";import{resolve as c,parse as j,isAbsolute as P,dirname as T}from"@visulima/path";import{toPath as f}from"@visulima/path/utils";import{FIND_UP_STOP as q}from"./FIND_UP_STOP-pQqZdUPw.js";let g;const w=t=>(g??=m(import.meta.url))(t),o=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,b=t=>{if(typeof o<"u"&&o.versions&&o.versions.node){const[e,i]=o.versions.node.split(".").map(Number);if(e>22||e===22&&i>=3||e===20&&i>=16)return o.getBuiltinModule(t)}return w(t)},{stat:v,lstat:A}=b("node:fs/promises"),F=async(t,e={})=>{if(typeof t!="string"&&!Array.isArray(t)&&typeof t!="function")throw new TypeError("The `name` argument must be of type `string` or `string[]`");const i=e.cwd?f(e.cwd):process.cwd();let s=c(i);const{root:a}=j(s),d=f(e.stopAt??a),y=c(s,d),u=e.type??"file",_=async function(n){return typeof t=="function"?[await t(n)]:typeof t=="string"?[t]:Array.isArray(t)?t:[t]};e.allowSymlinks??=!0;const h=e.allowSymlinks?v:A;for(;s;){const n=await _(s);for(let r of n){if(r===q)return;if(r===void 0)continue;Buffer.isBuffer(r)?r=r.toString():r instanceof URL&&(r=f(r));const l=P(r)?r:c(s,r);try{const p=await h(l);if(u==="file"&&p.isFile()||u==="directory"&&p.isDirectory())return l}catch{}}if(s===y||s===a)break;s=T(s)}};export{F as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createRequire as h}from"node:module";import{resolve as c,parse as A,isAbsolute as S,dirname as j}from"@visulima/path";import{toPath as f}from"@visulima/path/utils";import{FIND_UP_STOP as P}from"./FIND_UP_STOP-pQqZdUPw.js";let g;const m=t=>(g??=h(import.meta.url))(t),s=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,w=t=>{if(typeof s<"u"&&s.versions&&s.versions.node){const[e,i]=s.versions.node.split(".").map(Number);if(e>22||e===22&&i>=3||e===20&&i>=16)return s.getBuiltinModule(t)}return m(t)},{statSync:b,lstatSync:v}=w("node:fs"),k=(t,e={})=>{if(typeof t!="string"&&!Array.isArray(t)&&typeof t!="function")throw new TypeError("The `name` argument must be of type `string` or `string[]`");const i=e.cwd?f(e.cwd):process.cwd();let o=c(i);const{root:u}=A(o),y=f(e.stopAt??u),d=c(o,y),l=e.type??"file",p=function(r){return typeof t=="function"?[t(r)]:typeof t=="string"?[t]:Array.isArray(t)?t:[t]};e.allowSymlinks??=!0;const _=e.allowSymlinks?b:v;for(;o;){for(let r of p(o)){if(r===P)return;if(r===void 0)continue;Buffer.isBuffer(r)?r=r.toString():r instanceof URL&&(r=f(r));const n=S(r)?r:c(o,r);try{const a=_(n);if(l==="file"&&a.isFile()||l==="directory"&&a.isDirectory())return n}catch{}}if(o===d||o===u)break;o=j(o)}};export{k as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as t}from"./index-DGueExxA.js";const l=async(a,o)=>await t(a,o);export{l as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{g as a}from"./index-DGueExxA.js";const g=(o,t)=>a(o,t);export{g as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const h=/^(?:( )+|\t+)/,a="space";function E(e,t,n){return e&&t===a&&n===1}function I(e,t){const n=new Map;let o=0,c,s;for(const i of e.split(/\n/g)){if(!i)continue;const u=i.match(h);if(u===null)o=0,c="";else{const d=u[0].length,r=u[1]?a:"tab";if(E(t,r,d))continue;r!==c&&(o=0),c=r;let l=1,p=0;const y=d-o;if(o=d,y===0)l=0,p=1;else{const T=Math.abs(y);if(E(t,r,T))continue;s=N(r,T)}const f=n.get(s);n.set(s,f===void 0?[1,0]:[f[0]+l,f[1]+p])}}return n}function N(e,t){return(e===a?"s":"t")+String(t)}function g(e){const n=e[0]==="s"?a:"tab",o=Number(e.slice(1));return{type:n,amount:o}}function m(e){let t,n=0,o=0;for(const[c,[s,i]]of e)(s>n||s===n&&i>o)&&(n=s,o=i,t=c);return t}function _(e,t){return(e===a?" ":" ").repeat(t)}function k(e){if(typeof e!="string")throw new TypeError("Expected a string");let t=I(e,!0);t.size===0&&(t=I(e,!1));const n=m(t);let o,c=0,s="";return n!==void 0&&({type:o,amount:c}=g(n),s=_(o,c)),{amount:c,type:o,indent:s}}export{k as d};
|