| Offset 1, 5 lines modified | Offset 1, 5 lines modified | ||
| 1 | Zip·file·size:·26218 | 1 | Zip·file·size:·2621870·bytes,·number·of·entries:·3 |
| 2 | -rw-r--r--··4.5·unx·······30·bx·stor·26-Apr-05·07:23·metadata.json | 2 | -rw-r--r--··4.5·unx·······30·bx·stor·26-Apr-05·07:23·metadata.json |
| 3 | -rw-r--r--··4.5·unx··25377 | 3 | -rw-r--r--··4.5·unx··2537725·bx·stor·26-Apr-05·07:23·pkg-cspell-9.8.0-hfa286de_0.tar.zst |
| 4 | -rw-r--r--··4.5·unx····8357 | 4 | -rw-r--r--··4.5·unx····83577·bx·stor·26-Apr-05·07:23·info-cspell-9.8.0-hfa286de_0.tar.zst |
| 5 | 3·files,·26213 | 5 | 3·files,·2621332·bytes·uncompressed,·2621332·bytes·compressed:··0.0% |
| Offset 19, 121 lines modified | Offset 19, 121 lines modified | ||
| 19 | 00005D·LOCAL·HEADER·#2·······04034B50 | 19 | 00005D·LOCAL·HEADER·#2·······04034B50 |
| 20 | 000061·Extract·Zip·Spec······2D·'4.5' | 20 | 000061·Extract·Zip·Spec······2D·'4.5' |
| 21 | 000062·Extract·OS············00·'MS-DOS' | 21 | 000062·Extract·OS············00·'MS-DOS' |
| 22 | 000063·General·Purpose·Flag··0000 | 22 | 000063·General·Purpose·Flag··0000 |
| 23 | 000065·Compression·Method····0000·'Stored' | 23 | 000065·Compression·Method····0000·'Stored' |
| 24 | 000067·Last·Mod·Time·········5C853AF7·'Sun·Apr··5·07:23:46·2026' | 24 | 000067·Last·Mod·Time·········5C853AF7·'Sun·Apr··5·07:23:46·2026' |
| 25 | 00006B·CRC··················· | 25 | 00006B·CRC···················2AACC5C1 |
| 26 | 00006F·Compressed·Length·····FFFFFFFF | 26 | 00006F·Compressed·Length·····FFFFFFFF |
| 27 | 000073·Uncompressed·Length···FFFFFFFF | 27 | 000073·Uncompressed·Length···FFFFFFFF |
| 28 | 000077·Filename·Length·······0023 | 28 | 000077·Filename·Length·······0023 |
| 29 | 000079·Extra·Length··········0014 | 29 | 000079·Extra·Length··········0014 |
| 30 | 00007B·Filename··············'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX' | 30 | 00007B·Filename··············'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX' |
| 31 | 00009E·Extra·ID·#0001········0001·'ZIP64' | 31 | 00009E·Extra·ID·#0001········0001·'ZIP64' |
| 32 | 0000A0···Length··············0010 | 32 | 0000A0···Length··············0010 |
| 33 | 0000A2···Uncompressed·Size···000000000026B | 33 | 0000A2···Uncompressed·Size···000000000026B8FD |
| 34 | 0000AA···Compressed·Size·····000000000026B | 34 | 0000AA···Compressed·Size·····000000000026B8FD |
| 35 | 0000B2·PAYLOAD | 35 | 0000B2·PAYLOAD |
| 36 | 26B9 | 36 | 26B9AF·LOCAL·HEADER·#3·······04034B50 |
| 37 | 26B9 | 37 | 26B9B3·Extract·Zip·Spec······2D·'4.5' |
| 38 | 26B9 | 38 | 26B9B4·Extract·OS············00·'MS-DOS' |
| 39 | 26B9 | 39 | 26B9B5·General·Purpose·Flag··0000 |
| 40 | 26B9 | 40 | 26B9B7·Compression·Method····0000·'Stored' |
| 41 | 26B9 | 41 | 26B9B9·Last·Mod·Time·········5C853AF7·'Sun·Apr··5·07:23:46·2026' |
| 42 | 26B9 | 42 | 26B9BD·CRC···················1CB0B1FC |
| 43 | 26B9 | 43 | 26B9C1·Compressed·Length·····FFFFFFFF |
| 44 | 26B9 | 44 | 26B9C5·Uncompressed·Length···FFFFFFFF |
| 45 | 26B9 | 45 | 26B9C9·Filename·Length·······0024 |
| 46 | 26B9 | 46 | 26B9CB·Extra·Length··········0014 |
| 47 | 26B9 | 47 | 26B9CD·Filename··············'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX' |
| 48 | 26B | 48 | 26B9F1·Extra·ID·#0001········0001·'ZIP64' |
| 49 | 26B | 49 | 26B9F3···Length··············0010 |
| 50 | 26B | 50 | 26B9F5···Uncompressed·Size···0000000000014679 |
| 51 | 26B | 51 | 26B9FD···Compressed·Size·····0000000000014679 |
| 52 | 26BA | 52 | 26BA05·PAYLOAD |
| 53 | 2800 | 53 | 28007E·CENTRAL·HEADER·#1·····02014B50 |
| 54 | 2800 | 54 | 280082·Created·Zip·Spec······2D·'4.5' |
| 55 | 2800 | 55 | 280083·Created·OS············03·'Unix' |
| 56 | 2800 | 56 | 280084·Extract·Zip·Spec······2D·'4.5' |
| 57 | 2800 | 57 | 280085·Extract·OS············00·'MS-DOS' |
| 58 | 2800 | 58 | 280086·General·Purpose·Flag··0000 |
| 59 | 2800 | 59 | 280088·Compression·Method····0000·'Stored' |
| 60 | 2800 | 60 | 28008A·Last·Mod·Time·········5C853AF7·'Sun·Apr··5·07:23:46·2026' |
| 61 | 2800 | 61 | 28008E·CRC···················2E6500CB |
| 62 | 2800 | 62 | 280092·Compressed·Length·····FFFFFFFF |
| 63 | 2800 | 63 | 280096·Uncompressed·Length···FFFFFFFF |
| 64 | 2800 | 64 | 28009A·Filename·Length·······000D |
| 65 | 2800 | 65 | 28009C·Extra·Length··········0014 |
| 66 | 2800 | 66 | 28009E·Comment·Length········0000 |
| 67 | 2800 | 67 | 2800A0·Disk·Start············0000 |
| 68 | 2800 | 68 | 2800A2·Int·File·Attributes···0000 |
| 69 | ·······[Bit·0]···············0·'Binary·Data' | 69 | ·······[Bit·0]···············0·'Binary·Data' |
| 70 | 2800 | 70 | 2800A4·Ext·File·Attributes···81A40000 |
| 71 | 2800 | 71 | 2800A8·Local·Header·Offset···00000000 |
| 72 | 2800 | 72 | 2800AC·Filename··············'XXXXXXXXXXXXX' |
| 73 | 2800 | 73 | 2800B9·Extra·ID·#0001········0001·'ZIP64' |
| 74 | 2800 | 74 | 2800BB···Length··············0010 |
| 75 | 2800 | 75 | 2800BD···Uncompressed·Size···000000000000001E |
| 76 | 2800 | 76 | 2800C5···Compressed·Size·····000000000000001E |
| 77 | 2800 | 77 | 2800CD·CENTRAL·HEADER·#2·····02014B50 |
| 78 | 2800 | 78 | 2800D1·Created·Zip·Spec······2D·'4.5' |
| 79 | 2800 | 79 | 2800D2·Created·OS············03·'Unix' |
| 80 | 2800 | 80 | 2800D3·Extract·Zip·Spec······2D·'4.5' |
| 81 | 2800 | 81 | 2800D4·Extract·OS············00·'MS-DOS' |
| 82 | 2800 | 82 | 2800D5·General·Purpose·Flag··0000 |
| 83 | 2800 | 83 | 2800D7·Compression·Method····0000·'Stored' |
| 84 | 2800 | 84 | 2800D9·Last·Mod·Time·········5C853AF7·'Sun·Apr··5·07:23:46·2026' |
| 85 | 2800 | 85 | 2800DD·CRC···················2AACC5C1 |
| 86 | 2800 | 86 | 2800E1·Compressed·Length·····FFFFFFFF |
| 87 | 2800 | 87 | 2800E5·Uncompressed·Length···FFFFFFFF |
| 88 | 2800 | 88 | 2800E9·Filename·Length·······0023 |
| 89 | 280 | 89 | 2800EB·Extra·Length··········0014 |
| 90 | 280 | 90 | 2800ED·Comment·Length········0000 |
| 91 | 280 | 91 | 2800EF·Disk·Start············0000 |
| 92 | 280 | 92 | 2800F1·Int·File·Attributes···0000 |
| 93 | ·······[Bit·0]···············0·'Binary·Data' | 93 | ·······[Bit·0]···············0·'Binary·Data' |
| 94 | 280 | 94 | 2800F3·Ext·File·Attributes···81A40000 |
| 95 | 280 | 95 | 2800F7·Local·Header·Offset···0000005D |
| 96 | 280 | 96 | 2800FB·Filename··············'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX' |
| 97 | 2801 | 97 | 28011E·Extra·ID·#0001········0001·'ZIP64' |
| 98 | 2801 | 98 | 280120···Length··············0010 |
| 99 | 2801 | 99 | 280122···Uncompressed·Size···000000000026B8FD |
| 100 | 2801 | 100 | 28012A···Compressed·Size·····000000000026B8FD |
| 101 | 2801 | 101 | 280132·CENTRAL·HEADER·#3·····02014B50 |
| 102 | 2801 | 102 | 280136·Created·Zip·Spec······2D·'4.5' |
| 103 | 2801 | 103 | 280137·Created·OS············03·'Unix' |
| 104 | 2801 | 104 | 280138·Extract·Zip·Spec······2D·'4.5' |
| 105 | 2801 | 105 | 280139·Extract·OS············00·'MS-DOS' |
| 106 | 2801 | 106 | 28013A·General·Purpose·Flag··0000 |
| 107 | 2801 | 107 | 28013C·Compression·Method····0000·'Stored' |
| 108 | 2801 | 108 | 28013E·Last·Mod·Time·········5C853AF7·'Sun·Apr··5·07:23:46·2026' |
| 109 | 2801 | 109 | 280142·CRC···················1CB0B1FC |
| 110 | 2801 | 110 | 280146·Compressed·Length·····FFFFFFFF |
| 111 | 2801 | 111 | 28014A·Uncompressed·Length···FFFFFFFF |
| 112 | 2801 | 112 | 28014E·Filename·Length·······0024 |
| Max diff block lines reached; 1232/8711 bytes (14.14%) of diff not shown. | |||
| Offset 1349, 19 lines modified | Offset 1349, 19 lines modified | ||
| 1349 | -rw-r--r--···0········0········0·····2103·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/smol-toml/dist/struct.d.ts | 1349 | -rw-r--r--···0········0········0·····2103·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/smol-toml/dist/struct.d.ts |
| 1350 | -rw-r--r--···0········0········0·····7308·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/smol-toml/dist/struct.js | 1350 | -rw-r--r--···0········0········0·····7308·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/smol-toml/dist/struct.js |
| 1351 | -rw-r--r--···0········0········0·····2533·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/smol-toml/dist/util.d.ts | 1351 | -rw-r--r--···0········0········0·····2533·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/smol-toml/dist/util.d.ts |
| 1352 | -rw-r--r--···0········0········0·····4209·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/smol-toml/dist/util.js | 1352 | -rw-r--r--···0········0········0·····4209·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/smol-toml/dist/util.js |
| 1353 | -rw-r--r--···0········0········0·····1514·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/smol-toml/package.json | 1353 | -rw-r--r--···0········0········0·····1514·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/smol-toml/package.json |
| 1354 | -rw-r--r--···0········0········0·····1076·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/tinyglobby/LICENSE | 1354 | -rw-r--r--···0········0········0·····1076·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/tinyglobby/LICENSE |
| 1355 | -rw-r--r--···0········0········0······932·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/tinyglobby/README.md | 1355 | -rw-r--r--···0········0········0······932·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/tinyglobby/README.md |
| 1356 | -rw-r--r--···0········0········0····1 | 1356 | -rw-r--r--···0········0········0····13389·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/tinyglobby/dist/index.cjs |
| 1357 | -rw-r--r--···0········0········0·····46 | 1357 | -rw-r--r--···0········0········0·····4664·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/tinyglobby/dist/index.d.cts |
| 1358 | -rw-r--r--···0········0········0·····46 | 1358 | -rw-r--r--···0········0········0·····4664·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/tinyglobby/dist/index.d.mts |
| 1359 | -rw-r--r--···0········0········0····12 | 1359 | -rw-r--r--···0········0········0····12128·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/tinyglobby/dist/index.mjs |
| 1360 | -rw-r--r--···0········0········0·····18 | 1360 | -rw-r--r--···0········0········0·····1820·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/tinyglobby/package.json |
| 1361 | -rw-r--r--···0········0········0·····1095·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/License.txt | 1361 | -rw-r--r--···0········0········0·····1095·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/License.txt |
| 1362 | -rw-r--r--···0········0········0······933·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/README.md | 1362 | -rw-r--r--···0········0········0······933·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/README.md |
| 1363 | -rw-r--r--···0········0········0·····6347·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/lib/esm/main.d.ts | 1363 | -rw-r--r--···0········0········0·····6347·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/lib/esm/main.d.ts |
| 1364 | -rw-r--r--···0········0········0····10195·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/lib/esm/main.js | 1364 | -rw-r--r--···0········0········0····10195·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/lib/esm/main.js |
| 1365 | -rw-r--r--···0········0········0·······23·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/lib/esm/package.json | 1365 | -rw-r--r--···0········0········0·······23·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/lib/esm/package.json |
| 1366 | -rw-r--r--···0········0········0·····6347·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/lib/umd/main.d.ts | 1366 | -rw-r--r--···0········0········0·····6347·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/lib/umd/main.d.ts |
| 1367 | -rw-r--r--···0········0········0····13325·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/lib/umd/main.js | 1367 | -rw-r--r--···0········0········0····13325·2026-04-05·07:23:46.000000·lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/lib/umd/main.js |
| Offset 4, 15 lines modified | Offset 4, 15 lines modified | ||
| 4 | [](https://npmjs.com/package/tinyglobby) | 4 | [](https://npmjs.com/package/tinyglobby) |
| 5 | A·fast·and·minimal·alternative·to·globby·and·fast-glob,·meant·to·behave·the·same·way. | 5 | A·fast·and·minimal·alternative·to·globby·and·fast-glob,·meant·to·behave·the·same·way. |
| 6 | Both·globby·and·fast-glob·present·some·behavior·no·other·globbing·lib·has, | 6 | Both·globby·and·fast-glob·present·some·behavior·no·other·globbing·lib·has, |
| 7 | which·makes·it·hard·to·manually·replace·with·something·smaller·and·better. | 7 | which·makes·it·hard·to·manually·replace·with·something·smaller·and·better. |
| 8 | This·library·uses·only·two·subdependencies,·compared·to·`globby`'s·[23](https://npmgraph.js.org/?q=globby@1 | 8 | This·library·uses·only·two·subdependencies,·compared·to·`globby`'s·[23](https://npmgraph.js.org/?q=globby@16.2.0) |
| 9 | and·`fast-glob`'s·[17](https://npmgraph.js.org/[email protected]). | 9 | and·`fast-glob`'s·[17](https://npmgraph.js.org/[email protected]). |
| 10 | ##·Usage | 10 | ##·Usage |
| 11 | ```js | 11 | ```js |
| 12 | import·{·glob,·globSync·}·from·'tinyglobby'; | 12 | import·{·glob,·globSync·}·from·'tinyglobby'; |
| Offset 1, 887 lines modified | Offset 1, 837 lines modified | Diff chunk too large, falling back to line-by-line diff (837 lines added, 887 lines removed) | |
| 00000000:· | 00000000:·4f62·6a65·6374·2e64·6566·696e·6550·726f··Object.definePro | ||
| 00000010:·7 | 00000010:·7065·7274·7928·6578·706f·7274·732c·2053··perty(exports,·S | ||
| 00000020:· | 00000020:·796d·626f·6c2e·746f·5374·7269·6e67·5461··ymbol.toStringTa | ||
| 00000030:· | 00000030:·672c·207b·2076·616c·7565·3a20·224d·6f64··g,·{·value:·"Mod | ||
| 00000040:· | 00000040:·756c·6522·207d·293b·0a2f·2f23·7265·6769··ule"·});.//#regi | ||
| 00000050:·6 | 00000050:·6f6e·205c·3072·6f6c·6c64·6f77·6e2f·7275··on·\0rolldown/ru | ||
| 00000060:· | 00000060:·6e74·696d·652e·6a73·0a76·6172·205f·5f63··ntime.js.var·__c | ||
| 00000070:· | 00000070:·7265·6174·6520·3d20·4f62·6a65·6374·2e63··reate·=·Object.c | ||
| 00000080:·7 | 00000080:·7265·6174·653b·0a76·6172·205f·5f64·6566··reate;.var·__def | ||
| 00000090:· | 00000090:·5072·6f70·203d·204f·626a·6563·742e·6465··Prop·=·Object.de | ||
| 000000a0:· | 000000a0:·6669·6e65·5072·6f70·6572·7479·3b0a·7661··fineProperty;.va | ||
| 000000b0:· | 000000b0:·7220·5f5f·6765·744f·776e·5072·6f70·4465··r·__getOwnPropDe | ||
| 000000c0:·7 | 000000c0:·7363·203d·204f·626a·6563·742e·6765·744f··sc·=·Object.getO | ||
| 000000d0:· | 000000d0:·776e·5072·6f70·6572·7479·4465·7363·7269··wnPropertyDescri | ||
| 000000e0:· | 000000e0:·7074·6f72·3b0a·7661·7220·5f5f·6765·744f··ptor;.var·__getO | ||
| 000000f0:·7 | 000000f0:·776e·5072·6f70·4e61·6d65·7320·3d20·4f62··wnPropNames·=·Ob | ||
| 00000100:· | 00000100:·6a65·6374·2e67·6574·4f77·6e50·726f·7065··ject.getOwnPrope | ||
| 00000110:·7 | 00000110:·7274·794e·616d·6573·3b0a·7661·7220·5f5f··rtyNames;.var·__ | ||
| 00000120:· | 00000120:·6765·7450·726f·746f·4f66·203d·204f·626a··getProtoOf·=·Obj | ||
| 00000130:·6 | 00000130:·6563·742e·6765·7450·726f·746f·7479·7065··ect.getPrototype | ||
| 00000140:· | 00000140:·4f66·3b0a·7661·7220·5f5f·6861·734f·776e··Of;.var·__hasOwn | ||
| 00000150:· | 00000150:·5072·6f70·203d·204f·626a·6563·742e·7072··Prop·=·Object.pr | ||
| 00000160:· | 00000160:·6f74·6f74·7970·652e·6861·734f·776e·5072··ototype.hasOwnPr | ||
| 00000170:·6f | 00000170:·6f70·6572·7479·3b0a·7661·7220·5f5f·636f··operty;.var·__co | ||
| 00000180:·7 | 00000180:·7079·5072·6f70·7320·3d20·2874·6f2c·2066··pyProps·=·(to,·f | ||
| 00000190:· | 00000190:·726f·6d2c·2065·7863·6570·742c·2064·6573··rom,·except,·des | ||
| 000001a0:·6 | 000001a0:·6329·203d·3e20·7b0a·0969·6620·2866·726f··c)·=>·{..if·(fro | ||
| 000001b0:· | 000001b0:·6d20·2626·2074·7970·656f·6620·6672·6f6d··m·&&·typeof·from | ||
| 000001c0:·2 | 000001c0:·203d·3d3d·2022·6f62·6a65·6374·2220·7c7c···===·"object"·|| | ||
| 000001d0:·20 | 000001d0:·2074·7970·656f·6620·6672·6f6d·203d·3d3d···typeof·from·=== | ||
| 000001e0:· | 000001e0:·2022·6675·6e63·7469·6f6e·2229·2066·6f72···"function")·for | ||
| 000001f0:·20 | 000001f0:·2028·7661·7220·6b65·7973·203d·205f·5f67···(var·keys·=·__g | ||
| 00000200:·6 | 00000200:·6574·4f77·6e50·726f·704e·616d·6573·2866··etOwnPropNames(f | ||
| 00000210:· | 00000210:·726f·6d29·2c20·6920·3d20·302c·206e·203d··rom),·i·=·0,·n·= | ||
| 00000220:·206b·6579· | 00000220:·206b·6579·732e·6c65·6e67·7468·2c20·6b65···keys.length,·ke | ||
| 00000230:· | 00000230:·793b·2069·203c·206e·3b20·692b·2b29·207b··y;·i·<·n;·i++)·{ | ||
| 00000240:· | 00000240:·0a09·096b·6579·203d·206b·6579·735b·695d··...key·=·keys[i] | ||
| 00000250:· | 00000250:·3b0a·0909·6966·2028·215f·5f68·6173·4f77··;...if·(!__hasOw | ||
| 00000260:·6 | 00000260:·6e50·726f·702e·6361·6c6c·2874·6f2c·206b··nProp.call(to,·k | ||
| 00000270:· | 00000270:·6579·2920·2626·206b·6579·2021·3d3d·2065··ey)·&&·key·!==·e | ||
| 00000280:·7 | 00000280:·7863·6570·7429·205f·5f64·6566·5072·6f70··xcept)·__defProp | ||
| 00000290:· | 00000290:·2874·6f2c·206b·6579·2c20·7b0a·0909·0967··(to,·key,·{....g | ||
| 000002a0:· | 000002a0:·6574·3a20·2828·6b29·203d·3e20·6672·6f6d··et:·((k)·=>·from | ||
| 000002b0:· | 000002b0:·5b6b·5d29·2e62·696e·6428·6e75·6c6c·2c20··[k]).bind(null,· | ||
| 000002c0:· | 000002c0:·6b65·7929·2c0a·0909·0965·6e75·6d65·7261··key),....enumera | ||
| 000002d0:· | 000002d0:·626c·653a·2021·2864·6573·6320·3d20·5f5f··ble:·!(desc·=·__ | ||
| 000002e0:· | 000002e0:·6765·744f·776e·5072·6f70·4465·7363·2866··getOwnPropDesc(f | ||
| 000002f0:· | 000002f0:·726f·6d2c·206b·6579·2929·207c·7c20·6465··rom,·key))·||·de | ||
| 00000300:·3 | 00000300:·7363·2e65·6e75·6d65·7261·626c·650a·0909··sc.enumerable... | ||
| 00000310:· | 00000310:·7d29·3b0a·097d·0a09·7265·7475·726e·2074··});..}..return·t | ||
| 00000320:·6 | 00000320:·6f3b·0a7d·3b0a·7661·7220·5f5f·746f·4553··o;.};.var·__toES | ||
| 00000330:·286d·6f64· | 00000330:·4d20·3d20·286d·6f64·2c20·6973·4e6f·6465··M·=·(mod,·isNode | ||
| 00000340:·6f | 00000340:·4d6f·6465·2c20·7461·7267·6574·2920·3d3e··Mode,·target)·=> | ||
| 00000350:· | 00000350:·2028·7461·7267·6574·203d·206d·6f64·2021···(target·=·mod·! | ||
| 00000360:· | 00000360:·3d20·6e75·6c6c·203f·205f·5f63·7265·6174··=·null·?·__creat | ||
| 00000370:· | 00000370:·6528·5f5f·6765·7450·726f·746f·4f66·286d··e(__getProtoOf(m | ||
| 00000380:· | 00000380:·6f64·2929·203a·207b·7d2c·205f·5f63·6f70··od))·:·{},·__cop | ||
| 00000390:· | 00000390:·7950·726f·7073·2869·734e·6f64·654d·6f64··yProps(isNodeMod | ||
| 000003a0:· | 000003a0:·6520·7c7c·2021·6d6f·6420·7c7c·2021·6d6f··e·||·!mod·||·!mo | ||
| 000003b0:· | 000003b0:·642e·5f5f·6573·4d6f·6475·6c65·203f·205f··d.__esModule·?·_ | ||
| 000003c0:· | 000003c0:·5f64·6566·5072·6f70·2874·6172·6765·742c··_defProp(target, | ||
| 000003d0:· | 000003d0:·2022·6465·6661·756c·7422·2c20·7b0a·0976···"default",·{..v | ||
| 000003e0:·6 | 000003e0:·616c·7565·3a20·6d6f·642c·0a09·656e·756d··alue:·mod,..enum | ||
| 000003f0:· | 000003f0:·6572·6162·6c65·3a20·7472·7565·0a7d·2920··erable:·true.})· | ||
| 00000400:· | 00000400:·3a20·7461·7267·6574·2c20·6d6f·6429·293b··:·target,·mod)); | ||
| 00000410:· | 00000410:·0a2f·2f23·656e·6472·6567·696f·6e0a·6c65··.//#endregion.le | ||
| 00000420:·74 | 00000420:·7420·6673·203d·2072·6571·7569·7265·2822··t·fs·=·require(" | ||
| 00000430:· | 00000430:·6673·2229·3b0a·6c65·7420·7061·7468·203d··fs");.let·path·= | ||
| 00000440:· | 00000440:·2072·6571·7569·7265·2822·7061·7468·2229···require("path") | ||
| 00000450:· | 00000450:·3b0a·6c65·7420·7572·6c20·3d20·7265·7175··;.let·url·=·requ | ||
| 00000460:·6 | 00000460:·6972·6528·2275·726c·2229·3b0a·6c65·7420··ire("url");.let· | ||
| 00000470:·6 | 00000470:·6664·6972·203d·2072·6571·7569·7265·2822··fdir·=·require(" | ||
| 00000480:· | 00000480:·6664·6972·2229·3b0a·6c65·7420·7069·636f··fdir");.let·pico | ||
| 00000490:· | 00000490:·6d61·7463·6820·3d20·7265·7175·6972·6528··match·=·require( | ||
| 000004a0:· | 000004a0:·2270·6963·6f6d·6174·6368·2229·3b0a·7069··"picomatch");.pi | ||
| 000004b0:· | 000004b0:·636f·6d61·7463·6820·3d20·5f5f·746f·4553··comatch·=·__toES | ||
| 000004c0:· | 000004c0:·4d28·7069·636f·6d61·7463·6829·3b0a·2f2f··M(picomatch);.// | ||
| 000004d0:·2 | 000004d0:·2372·6567·696f·6e20·7372·632f·7574·696c··#region·src/util | ||
| 000004e0:· | 000004e0:·732e·7473·0a63·6f6e·7374·2069·7352·6561··s.ts.const·isRea | ||
| 000004f0:· | 000004f0:·646f·6e6c·7941·7272·6179·203d·2041·7272··donlyArray·=·Arr | ||
| 00000500:· | 00000500:·6179·2e69·7341·7272·6179·3b0a·636f·6e73··ay.isArray;.cons | ||
| 00000510:· | 00000510:·7420·4241·434b·534c·4153·4845·5320·3d20··t·BACKSLASHES·=· | ||
| 00000520:· | 00000520:·2f5c·5c2f·673b·0a63·6f6e·7374·2069·7357··/\\/g;.const·isW | ||
| 00000530:· | 00000530:·696e·203d·2070·726f·6365·7373·2e70·6c61··in·=·process.pla | ||
| 00000540:· | 00000540:·7466·6f72·6d20·3d3d·3d20·2277·696e·3332··tform·===·"win32 | ||
| 00000550:· | 00000550:·223b·0a63·6f6e·7374·204f·4e4c·595f·5041··";.const·ONLY_PA | ||
| 00000560:·2 | 00000560:·5245·4e54·5f44·4952·4543·544f·5249·4553··RENT_DIRECTORIES | ||
| 00000570:· | 00000570:·203d·202f·5e28·5c2f·3f5c·2e5c·2e29·2b24···=·/^(\/?\.\.)+$ | ||
| 00000580:· | 00000580:·2f3b·0a66·756e·6374·696f·6e20·6765·7450··/;.function·getP | ||
| 00000590:· | 00000590:·6172·7469·616c·4d61·7463·6865·7228·7061··artialMatcher(pa | ||
| 000005a0:· | 000005a0:·7474·6572·6e73·2c20·6f70·7469·6f6e·7320··tterns,·options· | ||
| 000005b0:· | 000005b0:·3d20·7b7d·2920·7b0a·0963·6f6e·7374·2070··=·{})·{..const·p | ||
| 000005c0:·6 | 000005c0:·6174·7465·726e·7343·6f75·6e74·203d·2070··atternsCount·=·p | ||
| 000005d0:· | 000005d0:·6174·7465·726e·732e·6c65·6e67·7468·3b0a··atterns.length;. | ||
| 000005e0:· | 000005e0:·0963·6f6e·7374·2070·6174·7465·726e·7350··.const·patternsP | ||
| 000005f0:· | 000005f0:·6172·7473·203d·2041·7272·6179·2870·6174··arts·=·Array(pat | ||
| 00000600:· | 00000600:·7465·726e·7343·6f75·6e74·293b·0a09·636f··ternsCount);..co | ||
| 00000610:· | 00000610:·6e73·7420·6d61·7463·6865·7273·203d·2041··nst·matchers·=·A | ||
| Max diff block lines reached; -1/118967 bytes (-0.00%) of diff not shown. | |||
| Offset 1, 39 lines modified | Offset 1, 11 lines modified | ||
| 1 | import·{·FSLike·}·from·"fdir"; | 1 | import·{·FSLike·}·from·"fdir"; |
| 2 | //#region·src/ | 2 | //#region·src/types.d.ts |
| 3 | type·FileSystemAdapter·=·Partial<FSLike>; | ||
| 3 | /** | ||
| 4 | *·Converts·a·path·to·a·pattern·depending·on·the·platform. | ||
| 5 | *·Identical·to·{@link·escapePath}·on·POSIX·systems. | ||
| 6 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#convertPathToPattern} | ||
| 7 | */ | ||
| 8 | declare·const·convertPathToPattern:·(path:·string)·=>·string; | ||
| 9 | /** | ||
| 10 | *·Escapes·a·path's·special·characters·depending·on·the·platform. | ||
| 11 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#escapePath} | ||
| 12 | */ | ||
| 13 | declare·const·escapePath:·(path:·string)·=>·string; | ||
| 14 | /** | ||
| 15 | *·Checks·if·a·pattern·has·dynamic·parts. | ||
| 16 | * | ||
| 17 | *·Has·a·few·minor·differences·with·[`fast-glob`](https://github.com/mrmlnc/fast-glob)·for·better·accuracy: | ||
| 18 | * | ||
| 19 | *·-·Doesn't·necessarily·return·`false`·on·patterns·that·include·`\`. | ||
| 20 | *·-·Returns·`true`·if·the·pattern·includes·parentheses,·regardless·of·them·representing·one·single·pattern·or·not. | ||
| 21 | *·-·Returns·`true`·for·unfinished·glob·extensions·i.e.·`(h`,·`+(h`. | ||
| 22 | *·-·Returns·`true`·for·unfinished·brace·expansions·as·long·as·they·include·`,`·or·`..`. | ||
| 23 | * | ||
| 24 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#isDynamicPattern} | ||
| 25 | */ | ||
| 26 | declare·function·isDynamicPattern(pattern:·string,·options?:·{ | ||
| 27 | ··caseSensitiveMatch:·boolean; | ||
| 28 | }):·boolean; | ||
| 29 | //#endregion | ||
| 30 | //#region·src/index.d.ts | ||
| 31 | interface·GlobOptions·{ | 4 | interface·GlobOptions·{ |
| 32 | ··/** | 5 | ··/** |
| 33 | ··*·Whether·to·return·absolute·paths.·Disable·to·have·relative·paths. | 6 | ··*·Whether·to·return·absolute·paths.·Disable·to·have·relative·paths. |
| 34 | ··*·@default·false | 7 | ··*·@default·false |
| 35 | ··*/ | 8 | ··*/ |
| 36 | ··absolute?:·boolean; | 9 | ··absolute?:·boolean; |
| 37 | ··/** | 10 | ··/** |
| Offset 120, 15 lines modified | Offset 92, 44 lines modified | ||
| 120 | ··patterns?:·string·|·readonly·string[]; | 92 | ··patterns?:·string·|·readonly·string[]; |
| 121 | ··/** | 93 | ··/** |
| 122 | ··*·An·`AbortSignal`·to·abort·crawling·the·file·system. | 94 | ··*·An·`AbortSignal`·to·abort·crawling·the·file·system. |
| 123 | ··*·@default·undefined | 95 | ··*·@default·undefined |
| 124 | ··*/ | 96 | ··*/ |
| 125 | ··signal?:·AbortSignal; | 97 | ··signal?:·AbortSignal; |
| 126 | } | 98 | } |
| 127 | 99 | //#endregion | |
| 100 | //#region·src/utils.d.ts | ||
| 101 | /** | ||
| 102 | *·Converts·a·path·to·a·pattern·depending·on·the·platform. | ||
| 103 | *·Identical·to·{@link·escapePath}·on·POSIX·systems. | ||
| 104 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#convertPathToPattern} | ||
| 105 | */ | ||
| 106 | declare·const·convertPathToPattern:·(path:·string)·=>·string; | ||
| 107 | /** | ||
| 108 | *·Escapes·a·path's·special·characters·depending·on·the·platform. | ||
| 109 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#escapePath} | ||
| 110 | */ | ||
| 111 | declare·const·escapePath:·(path:·string)·=>·string; | ||
| 112 | /** | ||
| 113 | *·Checks·if·a·pattern·has·dynamic·parts. | ||
| 114 | * | ||
| 115 | *·Has·a·few·minor·differences·with·[`fast-glob`](https://github.com/mrmlnc/fast-glob)·for·better·accuracy: | ||
| 116 | * | ||
| 117 | *·-·Doesn't·necessarily·return·`false`·on·patterns·that·include·`\`. | ||
| 118 | *·-·Returns·`true`·if·the·pattern·includes·parentheses,·regardless·of·them·representing·one·single·pattern·or·not. | ||
| 119 | *·-·Returns·`true`·for·unfinished·glob·extensions·i.e.·`(h`,·`+(h`. | ||
| 120 | *·-·Returns·`true`·for·unfinished·brace·expansions·as·long·as·they·include·`,`·or·`..`. | ||
| 121 | * | ||
| 122 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#isDynamicPattern} | ||
| 123 | */ | ||
| 124 | declare·function·isDynamicPattern(pattern:·string,·options?:·{ | ||
| 125 | ··caseSensitiveMatch:·boolean; | ||
| 126 | }):·boolean; | ||
| 127 | //#endregion | ||
| 128 | //#region·src/index.d.ts | ||
| 128 | /** | 129 | /** |
| 129 | *·Asynchronously·match·files·following·a·glob·pattern. | 130 | *·Asynchronously·match·files·following·a·glob·pattern. |
| 130 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#glob} | 131 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#glob} |
| 131 | */ | 132 | */ |
| 132 | declare·function·glob(patterns:·string·|·readonly·string[],·options?:·Omit<GlobOptions,·"patterns">):·Promise<string[]>; | 133 | declare·function·glob(patterns:·string·|·readonly·string[],·options?:·Omit<GlobOptions,·"patterns">):·Promise<string[]>; |
| 133 | /** | 134 | /** |
| 134 | *·@deprecated·Provide·patterns·as·the·first·argument·instead. | 135 | *·@deprecated·Provide·patterns·as·the·first·argument·instead. |
| Offset 140, 8 lines modified | Offset 141, 8 lines modified | ||
| 140 | */ | 141 | */ |
| 141 | declare·function·globSync(patterns:·string·|·readonly·string[],·options?:·Omit<GlobOptions,·"patterns">):·string[]; | 142 | declare·function·globSync(patterns:·string·|·readonly·string[],·options?:·Omit<GlobOptions,·"patterns">):·string[]; |
| 142 | /** | 143 | /** |
| 143 | *·@deprecated·Provide·patterns·as·the·first·argument·instead. | 144 | *·@deprecated·Provide·patterns·as·the·first·argument·instead. |
| 144 | */ | 145 | */ |
| 145 | declare·function·globSync(options:·GlobOptions):·string[]; | 146 | declare·function·globSync(options:·GlobOptions):·string[]; |
| 146 | //#endregion | 147 | //#endregion |
| 147 | export·{· | 148 | export·{·type·GlobOptions,·convertPathToPattern,·escapePath,·glob,·globSync,·isDynamicPattern·}; |
| Offset 1, 39 lines modified | Offset 1, 11 lines modified | ||
| 1 | import·{·FSLike·}·from·"fdir"; | 1 | import·{·FSLike·}·from·"fdir"; |
| 2 | //#region·src/ | 2 | //#region·src/types.d.ts |
| 3 | type·FileSystemAdapter·=·Partial<FSLike>; | ||
| 3 | /** | ||
| 4 | *·Converts·a·path·to·a·pattern·depending·on·the·platform. | ||
| 5 | *·Identical·to·{@link·escapePath}·on·POSIX·systems. | ||
| 6 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#convertPathToPattern} | ||
| 7 | */ | ||
| 8 | declare·const·convertPathToPattern:·(path:·string)·=>·string; | ||
| 9 | /** | ||
| 10 | *·Escapes·a·path's·special·characters·depending·on·the·platform. | ||
| 11 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#escapePath} | ||
| 12 | */ | ||
| 13 | declare·const·escapePath:·(path:·string)·=>·string; | ||
| 14 | /** | ||
| 15 | *·Checks·if·a·pattern·has·dynamic·parts. | ||
| 16 | * | ||
| 17 | *·Has·a·few·minor·differences·with·[`fast-glob`](https://github.com/mrmlnc/fast-glob)·for·better·accuracy: | ||
| 18 | * | ||
| 19 | *·-·Doesn't·necessarily·return·`false`·on·patterns·that·include·`\`. | ||
| 20 | *·-·Returns·`true`·if·the·pattern·includes·parentheses,·regardless·of·them·representing·one·single·pattern·or·not. | ||
| 21 | *·-·Returns·`true`·for·unfinished·glob·extensions·i.e.·`(h`,·`+(h`. | ||
| 22 | *·-·Returns·`true`·for·unfinished·brace·expansions·as·long·as·they·include·`,`·or·`..`. | ||
| 23 | * | ||
| 24 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#isDynamicPattern} | ||
| 25 | */ | ||
| 26 | declare·function·isDynamicPattern(pattern:·string,·options?:·{ | ||
| 27 | ··caseSensitiveMatch:·boolean; | ||
| 28 | }):·boolean; | ||
| 29 | //#endregion | ||
| 30 | //#region·src/index.d.ts | ||
| 31 | interface·GlobOptions·{ | 4 | interface·GlobOptions·{ |
| 32 | ··/** | 5 | ··/** |
| 33 | ··*·Whether·to·return·absolute·paths.·Disable·to·have·relative·paths. | 6 | ··*·Whether·to·return·absolute·paths.·Disable·to·have·relative·paths. |
| 34 | ··*·@default·false | 7 | ··*·@default·false |
| 35 | ··*/ | 8 | ··*/ |
| 36 | ··absolute?:·boolean; | 9 | ··absolute?:·boolean; |
| 37 | ··/** | 10 | ··/** |
| Offset 120, 15 lines modified | Offset 92, 44 lines modified | ||
| 120 | ··patterns?:·string·|·readonly·string[]; | 92 | ··patterns?:·string·|·readonly·string[]; |
| 121 | ··/** | 93 | ··/** |
| 122 | ··*·An·`AbortSignal`·to·abort·crawling·the·file·system. | 94 | ··*·An·`AbortSignal`·to·abort·crawling·the·file·system. |
| 123 | ··*·@default·undefined | 95 | ··*·@default·undefined |
| 124 | ··*/ | 96 | ··*/ |
| 125 | ··signal?:·AbortSignal; | 97 | ··signal?:·AbortSignal; |
| 126 | } | 98 | } |
| 127 | 99 | //#endregion | |
| 100 | //#region·src/utils.d.ts | ||
| 101 | /** | ||
| 102 | *·Converts·a·path·to·a·pattern·depending·on·the·platform. | ||
| 103 | *·Identical·to·{@link·escapePath}·on·POSIX·systems. | ||
| 104 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#convertPathToPattern} | ||
| 105 | */ | ||
| 106 | declare·const·convertPathToPattern:·(path:·string)·=>·string; | ||
| 107 | /** | ||
| 108 | *·Escapes·a·path's·special·characters·depending·on·the·platform. | ||
| 109 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#escapePath} | ||
| 110 | */ | ||
| 111 | declare·const·escapePath:·(path:·string)·=>·string; | ||
| 112 | /** | ||
| 113 | *·Checks·if·a·pattern·has·dynamic·parts. | ||
| 114 | * | ||
| 115 | *·Has·a·few·minor·differences·with·[`fast-glob`](https://github.com/mrmlnc/fast-glob)·for·better·accuracy: | ||
| 116 | * | ||
| 117 | *·-·Doesn't·necessarily·return·`false`·on·patterns·that·include·`\`. | ||
| 118 | *·-·Returns·`true`·if·the·pattern·includes·parentheses,·regardless·of·them·representing·one·single·pattern·or·not. | ||
| 119 | *·-·Returns·`true`·for·unfinished·glob·extensions·i.e.·`(h`,·`+(h`. | ||
| 120 | *·-·Returns·`true`·for·unfinished·brace·expansions·as·long·as·they·include·`,`·or·`..`. | ||
| 121 | * | ||
| 122 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#isDynamicPattern} | ||
| 123 | */ | ||
| 124 | declare·function·isDynamicPattern(pattern:·string,·options?:·{ | ||
| 125 | ··caseSensitiveMatch:·boolean; | ||
| 126 | }):·boolean; | ||
| 127 | //#endregion | ||
| 128 | //#region·src/index.d.ts | ||
| 128 | /** | 129 | /** |
| 129 | *·Asynchronously·match·files·following·a·glob·pattern. | 130 | *·Asynchronously·match·files·following·a·glob·pattern. |
| 130 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#glob} | 131 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#glob} |
| 131 | */ | 132 | */ |
| 132 | declare·function·glob(patterns:·string·|·readonly·string[],·options?:·Omit<GlobOptions,·"patterns">):·Promise<string[]>; | 133 | declare·function·glob(patterns:·string·|·readonly·string[],·options?:·Omit<GlobOptions,·"patterns">):·Promise<string[]>; |
| 133 | /** | 134 | /** |
| 134 | *·@deprecated·Provide·patterns·as·the·first·argument·instead. | 135 | *·@deprecated·Provide·patterns·as·the·first·argument·instead. |
| Offset 140, 8 lines modified | Offset 141, 8 lines modified | ||
| 140 | */ | 141 | */ |
| 141 | declare·function·globSync(patterns:·string·|·readonly·string[],·options?:·Omit<GlobOptions,·"patterns">):·string[]; | 142 | declare·function·globSync(patterns:·string·|·readonly·string[],·options?:·Omit<GlobOptions,·"patterns">):·string[]; |
| 142 | /** | 143 | /** |
| 143 | *·@deprecated·Provide·patterns·as·the·first·argument·instead. | 144 | *·@deprecated·Provide·patterns·as·the·first·argument·instead. |
| 144 | */ | 145 | */ |
| 145 | declare·function·globSync(options:·GlobOptions):·string[]; | 146 | declare·function·globSync(options:·GlobOptions):·string[]; |
| 146 | //#endregion | 147 | //#endregion |
| 147 | export·{· | 148 | export·{·type·GlobOptions,·convertPathToPattern,·escapePath,·glob,·globSync,·isDynamicPattern·}; |
| Offset 1, 59 lines modified | Offset 1, 58 lines modified | ||
| 1 | import·nativeFs·from·"fs"; | ||
| 2 | import·path,· | 1 | import·{·readdir,·readdirSync,·realpath,·realpathSync,·stat,·statSync·}·from·"fs"; |
| 2 | import·{·isAbsolute,·posix,·resolve·}·from·"path"; | ||
| 3 | import·{·fileURLToPath·}·from·"url"; | 3 | import·{·fileURLToPath·}·from·"url"; |
| 4 | import·{·fdir·}·from·"fdir"; | 4 | import·{·fdir·}·from·"fdir"; |
| 5 | import·picomatch·from·"picomatch"; | 5 | import·picomatch·from·"picomatch"; |
| 6 | //#region·src/utils.ts | 6 | //#region·src/utils.ts |
| 7 | const·isReadonlyArray·=·Array.isArray; | 7 | const·isReadonlyArray·=·Array.isArray; |
| 8 | const·BACKSLASHES·=·/\\/g; | ||
| 8 | const·isWin·=·process.platform·===·"win32"; | 9 | const·isWin·=·process.platform·===·"win32"; |
| 9 | const·ONLY_PARENT_DIRECTORIES·=·/^(\/?\.\.)+$/; | 10 | const·ONLY_PARENT_DIRECTORIES·=·/^(\/?\.\.)+$/; |
| 10 | function·getPartialMatcher(patterns,·options·=·{})·{ | 11 | function·getPartialMatcher(patterns,·options·=·{})·{ |
| 11 | » const·patternsCount·=·patterns.length; | 12 | » const·patternsCount·=·patterns.length; |
| 12 | » const·patternsParts·=·Array(patternsCount); | 13 | » const·patternsParts·=·Array(patternsCount); |
| 13 | » const·matchers·=·Array(patternsCount); | 14 | » const·matchers·=·Array(patternsCount); |
| 14 | » | 15 | » let·i,·j; |
| 15 | » for·( | 16 | » for·(i·=·0;·i·<·patternsCount;·i++)·{ |
| 16 | » » const·parts·=·splitPattern(patterns[i]); | 17 | » » const·parts·=·splitPattern(patterns[i]); |
| 17 | » » patternsParts[i]·=·parts; | 18 | » » patternsParts[i]·=·parts; |
| 18 | » » const·partsCount·=·parts.length; | 19 | » » const·partsCount·=·parts.length; |
| 19 | » » const·partMatchers·=·Array(partsCount); | 20 | » » const·partMatchers·=·Array(partsCount); |
| 20 | » » for·( | 21 | » » for·(j·=·0;·j·<·partsCount;·j++)·partMatchers[j]·=·picomatch(parts[j],·options); |
| 21 | » » matchers[i]·=·partMatchers; | 22 | » » matchers[i]·=·partMatchers; |
| 22 | » } | 23 | » } |
| 23 | » return·(input)·=>·{ | 24 | » return·(input)·=>·{ |
| 24 | » » const·inputParts·=·input.split("/"); | 25 | » » const·inputParts·=·input.split("/"); |
| 25 | » » if·(inputParts[0]·===·".."·&&·ONLY_PARENT_DIRECTORIES.test(input))·return·true; | 26 | » » if·(inputParts[0]·===·".."·&&·ONLY_PARENT_DIRECTORIES.test(input))·return·true; |
| 26 | » » for·( | 27 | » » for·(i·=·0;·i·<·patternsCount;·i++)·{ |
| 27 | » » » const·patternParts·=·patternsParts[i]; | 28 | » » » const·patternParts·=·patternsParts[i]; |
| 28 | » » » const·matcher·=·matchers[i]; | 29 | » » » const·matcher·=·matchers[i]; |
| 29 | » » » const·inputPatternCount·=·inputParts.length; | 30 | » » » const·inputPatternCount·=·inputParts.length; |
| 30 | » » » const·minParts·=·Math.min(inputPatternCount,·patternParts.length); | 31 | » » » const·minParts·=·Math.min(inputPatternCount,·patternParts.length); |
| 31 | » » » | 32 | » » » j·=·0; |
| 32 | » » » while·(j·<·minParts)·{ | 33 | » » » while·(j·<·minParts)·{ |
| 33 | » » » » const·part·=·patternParts[j]; | 34 | » » » » const·part·=·patternParts[j]; |
| 34 | » » » » if·(part.includes("/"))·return·true; | 35 | » » » » if·(part.includes("/"))·return·true; |
| 36 | » » » » if·(!matcher[j](inputParts[j]))·break; | ||
| 35 | » » » » const·match·=·matcher[j](inputParts[j]); | ||
| 36 | » » » » if·(!match)·break; | ||
| 37 | » » » » if·( | 37 | » » » » if·(!options.noglobstar·&&·part·===·"**")·return·true; |
| 38 | » » » » j++; | 38 | » » » » j++; |
| 39 | » » » } | 39 | » » » } |
| 40 | » » » if·(j·===·inputPatternCount)·return·true; | 40 | » » » if·(j·===·inputPatternCount)·return·true; |
| 41 | » » } | 41 | » » } |
| 42 | » » return·false; | 42 | » » return·false; |
| 43 | » }; | 43 | » }; |
| 44 | } | 44 | } |
| 45 | /*·node:coverage·ignore·next·2·*/ | 45 | /*·node:coverage·ignore·next·2·*/ |
| 46 | const·WIN32_ROOT_DIR·=·/^[A-Z]:\/$/i; | 46 | const·WIN32_ROOT_DIR·=·/^[A-Z]:\/$/i; |
| 47 | const·isRoot·=·isWin·?·(p)·=>·WIN32_ROOT_DIR.test(p)·:·(p)·=>·p·===·"/"; | 47 | const·isRoot·=·isWin·?·(p)·=>·WIN32_ROOT_DIR.test(p)·:·(p)·=>·p·===·"/"; |
| 48 | function·buildFormat(cwd,·root,·absolute)·{ | 48 | function·buildFormat(cwd,·root,·absolute)·{ |
| 49 | » if·(cwd·===·root·||·root.startsWith(`${cwd}/`))·{ | 49 | » if·(cwd·===·root·||·root.startsWith(`${cwd}/`))·{ |
| 50 | » » if·(absolute)·{ | 50 | » » if·(absolute)·{ |
| 51 | » » » const·start·=· | 51 | » » » const·start·=·cwd.length·+·+!isRoot(cwd); |
| 52 | » » » return·(p,·isDir)·=>·p.slice(start,·isDir·?·-1·:·void·0)·||·"."; | 52 | » » » return·(p,·isDir)·=>·p.slice(start,·isDir·?·-1·:·void·0)·||·"."; |
| 53 | » » } | 53 | » » } |
| 54 | » » const·prefix·=·root.slice(cwd.length·+·1); | 54 | » » const·prefix·=·root.slice(cwd.length·+·1); |
| 55 | » » if·(prefix)·return·(p,·isDir)·=>·{ | 55 | » » if·(prefix)·return·(p,·isDir)·=>·{ |
| 56 | » » » if·(p·===·".")·return·prefix; | 56 | » » » if·(p·===·".")·return·prefix; |
| 57 | » » » const·result·=·`${prefix}/${p}`; | 57 | » » » const·result·=·`${prefix}/${p}`; |
| 58 | » » » return·isDir·?·result.slice(0,·-1)·:·result; | 58 | » » » return·isDir·?·result.slice(0,·-1)·:·result; |
| Offset 66, 42 lines modified | Offset 65, 41 lines modified | ||
| 66 | function·buildRelative(cwd,·root)·{ | 65 | function·buildRelative(cwd,·root)·{ |
| 67 | » if·(root.startsWith(`${cwd}/`))·{ | 66 | » if·(root.startsWith(`${cwd}/`))·{ |
| 68 | » » const·prefix·=·root.slice(cwd.length·+·1); | 67 | » » const·prefix·=·root.slice(cwd.length·+·1); |
| 69 | » » return·(p)·=>·`${prefix}/${p}`; | 68 | » » return·(p)·=>·`${prefix}/${p}`; |
| 70 | » } | 69 | » } |
| 71 | » return·(p)·=>·{ | 70 | » return·(p)·=>·{ |
| 72 | » » const·result·=·posix.relative(cwd,·`${root}/${p}`); | 71 | » » const·result·=·posix.relative(cwd,·`${root}/${p}`); |
| 72 | » » return·p[p.length·-·1]·===·"/"·&&·result·!==·""·?·`${result}/`·:·result·||·"."; | ||
| 73 | » » if·(p.endsWith("/")·&&·result·!==·"")·return·`${result}/`; | ||
| 74 | » » return·result·||·"."; | ||
| 75 | » }; | 73 | » }; |
| 76 | } | 74 | } |
| 77 | const·splitPatternOptions·=·{·parts:·true·}; | 75 | const·splitPatternOptions·=·{·parts:·true·}; |
| 78 | function·splitPattern(path | 76 | function·splitPattern(path)·{ |
| 79 | » var·_result$parts; | 77 | » var·_result$parts; |
| 80 | » const·result·=·picomatch.scan(path | 78 | » const·result·=·picomatch.scan(path,·splitPatternOptions); |
| 81 | » return·((_result$parts·=·result.parts)·===·null·||·_result$parts·===·void·0·?·void·0·:·_result$parts.length)·?·result.parts·:·[path | 79 | » return·((_result$parts·=·result.parts)·===·null·||·_result$parts·===·void·0·?·void·0·:·_result$parts.length)·?·result.parts·:·[path]; |
| 82 | } | 80 | } |
| 83 | const·ESCAPED_WIN32_BACKSLASHES·=·/\\(?![()[\]{}!+@])/g; | 81 | const·ESCAPED_WIN32_BACKSLASHES·=·/\\(?![()[\]{}!+@])/g; |
| 84 | function·convertPosixPathToPattern(path | 82 | function·convertPosixPathToPattern(path)·{ |
| 85 | » return·escapePosixPath(path | 83 | » return·escapePosixPath(path); |
| 86 | } | 84 | } |
| 87 | function·convertWin32PathToPattern(path | 85 | function·convertWin32PathToPattern(path)·{ |
| 88 | » return·escapeWin32Path(path | 86 | » return·escapeWin32Path(path).replace(ESCAPED_WIN32_BACKSLASHES,·"/"); |
| 89 | } | 87 | } |
| 90 | /** | 88 | /** |
| 91 | *·Converts·a·path·to·a·pattern·depending·on·the·platform. | 89 | *·Converts·a·path·to·a·pattern·depending·on·the·platform. |
| 92 | *·Identical·to·{@link·escapePath}·on·POSIX·systems. | 90 | *·Identical·to·{@link·escapePath}·on·POSIX·systems. |
| 93 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#convertPathToPattern} | 91 | *·@see·{@link·https://superchupu.dev/tinyglobby/documentation#convertPathToPattern} |
| 94 | */ | 92 | */ |
| 95 | /*·node:coverage·ignore·next·3·*/ | 93 | /*·node:coverage·ignore·next·3·*/ |
| 96 | const·convertPathToPattern·=·isWin·?·convertWin32PathToPattern·:·convertPosixPathToPattern; | 94 | const·convertPathToPattern·=·isWin·?·convertWin32PathToPattern·:·convertPosixPathToPattern; |
| 97 | const·POSIX_UNESCAPED_GLOB_SYMBOLS·=·/(?<!\\)([()[\]{}*?|]|^!|[!+@](?=\()|\\(?![()[\]{}!*+?@|]))/g; | 95 | const·POSIX_UNESCAPED_GLOB_SYMBOLS·=·/(?<!\\)([()[\]{}*?|]|^!|[!+@](?=\()|\\(?![()[\]{}!*+?@|]))/g; |
| 98 | const·WIN32_UNESCAPED_GLOB_SYMBOLS·=·/(?<!\\)([()[\]{}]|^!|[!+@](?=\())/g; | 96 | const·WIN32_UNESCAPED_GLOB_SYMBOLS·=·/(?<!\\)([()[\]{}]|^!|[!+@](?=\())/g; |
| 99 | const·escapePosixPath·=·(path | 97 | const·escapePosixPath·=·(path)·=>·path.replace(POSIX_UNESCAPED_GLOB_SYMBOLS,·"\\$&"); |
| 100 | const·escapeWin32Path·=·(path | 98 | const·escapeWin32Path·=·(path)·=>·path.replace(WIN32_UNESCAPED_GLOB_SYMBOLS,·"\\$&"); |
| Max diff block lines reached; 13883/18895 bytes (73.47%) of diff not shown. | |||
| Offset 1, 27 lines modified | Offset 1, 27 lines modified | ||
| 1 | { | 1 | { |
| 2 | ····"author":·"Superchupu", | 2 | ····"author":·"Superchupu", |
| 3 | ····"bugs":·{ | 3 | ····"bugs":·{ |
| 4 | ········"url":·"https://github.com/SuperchupuDev/tinyglobby/issues" | 4 | ········"url":·"https://github.com/SuperchupuDev/tinyglobby/issues" |
| 5 | ····}, | 5 | ····}, |
| 6 | ····"dependencies":·{ | 6 | ····"dependencies":·{ |
| 7 | ········"fdir":·"^6.5.0", | 7 | ········"fdir":·"^6.5.0", |
| 8 | ········"picomatch":·"^4.0. | 8 | ········"picomatch":·"^4.0.4" |
| 9 | ····}, | 9 | ····}, |
| 10 | ····"description":·"A·fast·and·minimal·alternative·to·globby·and·fast-glob", | 10 | ····"description":·"A·fast·and·minimal·alternative·to·globby·and·fast-glob", |
| 11 | ····"devDependencies":·{ | 11 | ····"devDependencies":·{ |
| 12 | ········"@biomejs/biome":·"^2. | 12 | ········"@biomejs/biome":·"^2.4.10", |
| 13 | ········"@types/node":·"^2 | 13 | ········"@types/node":·"^25.5.2", |
| 14 | ········"@types/picomatch":·"^4.0. | 14 | ········"@types/picomatch":·"^4.0.3", |
| 15 | ········"fast-glob":·"^3.3.3", | 15 | ········"fast-glob":·"^3.3.3", |
| 16 | ········"fs-fixture":·"^2. | 16 | ········"fs-fixture":·"^2.13.0", |
| 17 | ········"glob":·"^1 | 17 | ········"glob":·"^13.0.6", |
| 18 | ········"tinybench":·"^ | 18 | ········"tinybench":·"^6.0.0", |
| 19 | ········"tsdown":·"^0. | 19 | ········"tsdown":·"^0.21.7", |
| 20 | ········"typescript":·"^ | 20 | ········"typescript":·"^6.0.2" |
| 21 | ····}, | 21 | ····}, |
| 22 | ····"engines":·{ | 22 | ····"engines":·{ |
| 23 | ········"node":·">=12.0.0" | 23 | ········"node":·">=12.0.0" |
| 24 | ····}, | 24 | ····}, |
| 25 | ····"exports":·{ | 25 | ····"exports":·{ |
| 26 | ········".":·{ | 26 | ········".":·{ |
| 27 | ············"import":·"./dist/index.mjs", | 27 | ············"import":·"./dist/index.mjs", |
| Offset 65, 9 lines modified | Offset 65, 9 lines modified | ||
| 65 | ········"test:coverage":·"node·--test·--experimental-test-coverage·\"test/**/*.ts\"", | 65 | ········"test:coverage":·"node·--test·--experimental-test-coverage·\"test/**/*.ts\"", |
| 66 | ········"test:only":·"node·--test·--test-only·\"test/**/*.ts\"", | 66 | ········"test:only":·"node·--test·--test-only·\"test/**/*.ts\"", |
| 67 | ········"typecheck":·"tsc·--noEmit" | 67 | ········"typecheck":·"tsc·--noEmit" |
| 68 | ····}, | 68 | ····}, |
| 69 | ····"sideEffects":·false, | 69 | ····"sideEffects":·false, |
| 70 | ····"type":·"module", | 70 | ····"type":·"module", |
| 71 | ····"types":·"./dist/index.d.cts", | 71 | ····"types":·"./dist/index.d.cts", |
| 72 | ····"version":·"0.2.1 | 72 | ····"version":·"0.2.16" |
| 73 | } | 73 | } |
| Offset 8093, 15 lines modified | Offset 8093, 15 lines modified | ||
| 0001f9c0:·2054·4845·2055·5345·204f·5220·4f54·4845···THE·USE·OR·OTHE | 0001f9c0:·2054·4845·2055·5345·204f·5220·4f54·4845···THE·USE·OR·OTHE | ||
| 0001f9d0:·5220·4445·414c·494e·4753·2049·4e20·5448··R·DEALINGS·IN·TH | 0001f9d0:·5220·4445·414c·494e·4753·2049·4e20·5448··R·DEALINGS·IN·TH | ||
| 0001f9e0:·4520·534f·4654·5741·5245·2e0a·0a2d·2d2d··E·SOFTWARE...--- | 0001f9e0:·4520·534f·4654·5741·5245·2e0a·0a2d·2d2d··E·SOFTWARE...--- | ||
| 0001f9f0:·0a0a·5468·6520·666f·6c6c·6f77·696e·6720··..The·following· | 0001f9f0:·0a0a·5468·6520·666f·6c6c·6f77·696e·6720··..The·following· | ||
| 0001fa00:·736f·6674·7761·7265·206d·6179·2062·6520··software·may·be· | 0001fa00:·736f·6674·7761·7265·206d·6179·2062·6520··software·may·be· | ||
| 0001fa10:·696e·636c·7564·6564·2069·6e20·7468·6973··included·in·this | 0001fa10:·696e·636c·7564·6564·2069·6e20·7468·6973··included·in·this | ||
| 0001fa20:·2070·726f·6475·6374·3a20·7469·6e79·676c···product:·tinygl | 0001fa20:·2070·726f·6475·6374·3a20·7469·6e79·676c···product:·tinygl | ||
| 0001fa30:·6f62·6279·2028·302e·322e·313 | 0001fa30:·6f62·6279·2028·302e·322e·3136·290a·5468··obby·(0.2.16).Th | ||
| 0001fa40:·6973·2073·6f66·7477·6172·6520·636f·6e74··is·software·cont | 0001fa40:·6973·2073·6f66·7477·6172·6520·636f·6e74··is·software·cont | ||
| 0001fa50:·6169·6e73·2074·6865·2066·6f6c·6c6f·7769··ains·the·followi | 0001fa50:·6169·6e73·2074·6865·2066·6f6c·6c6f·7769··ains·the·followi | ||
| 0001fa60:·6e67·206c·6963·656e·7365·2061·6e64·206e··ng·license·and·n | 0001fa60:·6e67·206c·6963·656e·7365·2061·6e64·206e··ng·license·and·n | ||
| 0001fa70:·6f74·6963·6520·6265·6c6f·773a·0a0a·4d49··otice·below:..MI | 0001fa70:·6f74·6963·6520·6265·6c6f·773a·0a0a·4d49··otice·below:..MI | ||
| 0001fa80:·5420·4c69·6365·6e73·650a·0a43·6f70·7972··T·License..Copyr | 0001fa80:·5420·4c69·6365·6e73·650a·0a43·6f70·7972··T·License..Copyr | ||
| 0001fa90:·6967·6874·2028·6329·2032·3032·3420·4d61··ight·(c)·2024·Ma | 0001fa90:·6967·6874·2028·6329·2032·3032·3420·4d61··ight·(c)·2024·Ma | ||
| 0001faa0:·6465·6c69·6e65·2047·7572·7269·6172·c3a1··deline·Gurriar.. | 0001faa0:·6465·6c69·6e65·2047·7572·7269·6172·c3a1··deline·Gurriar.. |
| Offset 8123, 46 lines modified | Offset 8123, 46 lines modified | ||
| 8123 | ············"path_type":·"hardlink", | 8123 | ············"path_type":·"hardlink", |
| 8124 | ············"sha256":·"22c68811e174cbbfb3813d4135918df4f540959c14d872e601d9abe83d3cde8f", | 8124 | ············"sha256":·"22c68811e174cbbfb3813d4135918df4f540959c14d872e601d9abe83d3cde8f", |
| 8125 | ············"size_in_bytes":·1076 | 8125 | ············"size_in_bytes":·1076 |
| 8126 | ········}, | 8126 | ········}, |
| 8127 | ········{ | 8127 | ········{ |
| 8128 | ············"_path":·"lib/node_modules/cspell/node_modules/tinyglobby/README.md", | 8128 | ············"_path":·"lib/node_modules/cspell/node_modules/tinyglobby/README.md", |
| 8129 | ············"path_type":·"hardlink", | 8129 | ············"path_type":·"hardlink", |
| 8130 | ············"sha256":·" | 8130 | ············"sha256":·"49a9d1ada3d563eda52d34b202dd0f254228897010e79a0cab804e5e80832eb7", |
| 8131 | ············"size_in_bytes":·932 | 8131 | ············"size_in_bytes":·932 |
| 8132 | ········}, | 8132 | ········}, |
| 8133 | ········{ | 8133 | ········{ |
| 8134 | ············"_path":·"lib/node_modules/cspell/node_modules/tinyglobby/dist/index.cjs", | 8134 | ············"_path":·"lib/node_modules/cspell/node_modules/tinyglobby/dist/index.cjs", |
| 8135 | ············"path_type":·"hardlink", | 8135 | ············"path_type":·"hardlink", |
| 8136 | ············"sha256":·" | 8136 | ············"sha256":·"0657547bf08e18693c45c3f9221a2e8f7829f248bf8e733ec46af64b17bb9455", |
| 8137 | ············"size_in_bytes":·1 | 8137 | ············"size_in_bytes":·13389 |
| 8138 | ········}, | 8138 | ········}, |
| 8139 | ········{ | 8139 | ········{ |
| 8140 | ············"_path":·"lib/node_modules/cspell/node_modules/tinyglobby/dist/index.d.cts", | 8140 | ············"_path":·"lib/node_modules/cspell/node_modules/tinyglobby/dist/index.d.cts", |
| 8141 | ············"path_type":·"hardlink", | 8141 | ············"path_type":·"hardlink", |
| 8142 | ············"sha256":·" | 8142 | ············"sha256":·"9cc8b473133250ba7af0b9d06d0595728a3f293c350e4f51f0eedd6b0f47d2a3", |
| 8143 | ············"size_in_bytes":·46 | 8143 | ············"size_in_bytes":·4664 |
| 8144 | ········}, | 8144 | ········}, |
| 8145 | ········{ | 8145 | ········{ |
| 8146 | ············"_path":·"lib/node_modules/cspell/node_modules/tinyglobby/dist/index.d.mts", | 8146 | ············"_path":·"lib/node_modules/cspell/node_modules/tinyglobby/dist/index.d.mts", |
| 8147 | ············"path_type":·"hardlink", | 8147 | ············"path_type":·"hardlink", |
| 8148 | ············"sha256":·" | 8148 | ············"sha256":·"9cc8b473133250ba7af0b9d06d0595728a3f293c350e4f51f0eedd6b0f47d2a3", |
| 8149 | ············"size_in_bytes":·46 | 8149 | ············"size_in_bytes":·4664 |
| 8150 | ········}, | 8150 | ········}, |
| 8151 | ········{ | 8151 | ········{ |
| 8152 | ············"_path":·"lib/node_modules/cspell/node_modules/tinyglobby/dist/index.mjs", | 8152 | ············"_path":·"lib/node_modules/cspell/node_modules/tinyglobby/dist/index.mjs", |
| 8153 | ············"path_type":·"hardlink", | 8153 | ············"path_type":·"hardlink", |
| 8154 | ············"sha256":·" | 8154 | ············"sha256":·"a85a34ece1ca0183ffff316aa69893ba23317427e5fa0da30b37571ec8adf819", |
| 8155 | ············"size_in_bytes":·12 | 8155 | ············"size_in_bytes":·12128 |
| 8156 | ········}, | 8156 | ········}, |
| 8157 | ········{ | 8157 | ········{ |
| 8158 | ············"_path":·"lib/node_modules/cspell/node_modules/tinyglobby/package.json", | 8158 | ············"_path":·"lib/node_modules/cspell/node_modules/tinyglobby/package.json", |
| 8159 | ············"path_type":·"hardlink", | 8159 | ············"path_type":·"hardlink", |
| 8160 | ············"sha256":·" | 8160 | ············"sha256":·"83419fbcd0e8b6b1fadd70f647cba140e9fc7f59748525541b9874fa1fae152e", |
| 8161 | ············"size_in_bytes":·18 | 8161 | ············"size_in_bytes":·1820 |
| 8162 | ········}, | 8162 | ········}, |
| 8163 | ········{ | 8163 | ········{ |
| 8164 | ············"_path":·"lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/License.txt", | 8164 | ············"_path":·"lib/node_modules/cspell/node_modules/vscode-languageserver-textdocument/License.txt", |
| 8165 | ············"path_type":·"hardlink", | 8165 | ············"path_type":·"hardlink", |
| 8166 | ············"sha256":·"ec9ee83580841e8eb687aca9867f221503809ba6426c7f876ede17d91b9fcfd0", | 8166 | ············"sha256":·"ec9ee83580841e8eb687aca9867f221503809ba6426c7f876ede17d91b9fcfd0", |
| 8167 | ············"size_in_bytes":·1095 | 8167 | ············"size_in_bytes":·1095 |
| 8168 | ········}, | 8168 | ········}, |