Updated the project.
This commit is contained in:
parent
5dfe9f128d
commit
7919556077
1550 changed files with 17063 additions and 40183 deletions
0
my-app/node_modules/path-scurry/LICENSE.md
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/LICENSE.md
generated
vendored
Executable file → Normal file
63
my-app/node_modules/path-scurry/README.md
generated
vendored
Executable file → Normal file
63
my-app/node_modules/path-scurry/README.md
generated
vendored
Executable file → Normal file
|
@ -21,9 +21,9 @@ folder tree, such that:
|
|||
`readdir()` or `stat()` covered the path, and
|
||||
`ent.isDirectory()` is false.)
|
||||
3. `path.resolve()`, `dirname()`, `basename()`, and other
|
||||
string-parsing/munging operations are be minimized. This
|
||||
means it has to track "provisional" child nodes that may not
|
||||
exist (and if we find that they _don't_ exist, store that
|
||||
string-parsing/munging operations are be minimized. This means
|
||||
it has to track "provisional" child nodes that may not exist
|
||||
(and if we find that they _don't_ exist, store that
|
||||
information as well, so we don't have to ever check again).
|
||||
4. The API is not limited to use as a stream/iterator/etc. There
|
||||
are many cases where an API like node's `fs` is preferrable.
|
||||
|
@ -49,9 +49,9 @@ convenience.
|
|||
|
||||
Benchmarks can be run by executing `npm run bench`.
|
||||
|
||||
As is always the case, doing more means going slower, doing
|
||||
less means going faster, and there are trade offs between speed
|
||||
and memory usage.
|
||||
As is always the case, doing more means going slower, doing less
|
||||
means going faster, and there are trade offs between speed and
|
||||
memory usage.
|
||||
|
||||
PathScurry makes heavy use of [LRUCache](http://npm.im/lru-cache)
|
||||
to efficiently cache whatever it can, and `Path` objects remain
|
||||
|
@ -82,8 +82,8 @@ With default settings on a folder tree of 100,000 items,
|
|||
consisting of around a 10-to-1 ratio of normal files to
|
||||
directories, PathScurry performs comparably to
|
||||
[@nodelib/fs.walk](http://npm.im/@nodelib/fs.walk), which is the
|
||||
fastest and most reliable file system walker I could find. As
|
||||
far as I can tell, it's almost impossible to go much faster in a
|
||||
fastest and most reliable file system walker I could find. As far
|
||||
as I can tell, it's almost impossible to go much faster in a
|
||||
Node.js program, just based on how fast you can push syscalls out
|
||||
to the fs thread pool.
|
||||
|
||||
|
@ -271,14 +271,14 @@ The options object that may be passed to all walk methods.
|
|||
falsey value. This will not prevent directories from being
|
||||
traversed if they do not pass the filter, though it will
|
||||
prevent the directories themselves from being included in the
|
||||
results. By default, if no filter is provided, then all
|
||||
entries are included in the results.
|
||||
- `walkFilter`: Function `(entry: Path) => boolean`. If
|
||||
provided, will prevent the traversal of any directory (or in
|
||||
the case of `follow:true` symbolic links to directories) for
|
||||
which the function returns false. This will not prevent the
|
||||
directories themselves from being included in the result set.
|
||||
Use `filter` for that.
|
||||
results. By default, if no filter is provided, then all entries
|
||||
are included in the results.
|
||||
- `walkFilter`: Function `(entry: Path) => boolean`. If provided,
|
||||
will prevent the traversal of any directory (or in the case of
|
||||
`follow:true` symbolic links to directories) for which the
|
||||
function returns false. This will not prevent the directories
|
||||
themselves from being included in the result set. Use `filter`
|
||||
for that.
|
||||
|
||||
Note that TypeScript return types will only be inferred properly
|
||||
from static analysis if the `withFileTypes` option is omitted, or
|
||||
|
@ -286,8 +286,8 @@ a constant `true` or `false` value.
|
|||
|
||||
### Class `PathScurry`
|
||||
|
||||
The main interface. Defaults to an appropriate class based on
|
||||
the current platform.
|
||||
The main interface. Defaults to an appropriate class based on the
|
||||
current platform.
|
||||
|
||||
Use `PathScurryWin32`, `PathScurryDarwin`, or `PathScurryPosix`
|
||||
if implementation-specific behavior is desired.
|
||||
|
@ -319,15 +319,15 @@ This is also the default sync iterator method.
|
|||
#### `pw.stream(entry?: string | Path | WalkOptions, opts?: WalkOptions)`
|
||||
|
||||
Return a [Minipass](http://npm.im/minipass) stream that emits
|
||||
each entry or path string in the walk. Results are made
|
||||
available asynchronously.
|
||||
each entry or path string in the walk. Results are made available
|
||||
asynchronously.
|
||||
|
||||
#### `pw.streamSync(entry?: string | Path | WalkOptions, opts?: WalkOptions)`
|
||||
|
||||
Return a [Minipass](http://npm.im/minipass) stream that emits
|
||||
each entry or path string in the walk. Results are made
|
||||
available synchronously, meaning that the walk will complete in a
|
||||
single tick if the stream is fully consumed.
|
||||
each entry or path string in the walk. Results are made available
|
||||
synchronously, meaning that the walk will complete in a single
|
||||
tick if the stream is fully consumed.
|
||||
|
||||
#### `pw.cwd`
|
||||
|
||||
|
@ -352,8 +352,8 @@ Root entries have a depth of `0`.
|
|||
Caching `path.resolve()`.
|
||||
|
||||
Significantly faster than `path.resolve()` if called repeatedly
|
||||
with the same paths. Significantly slower otherwise, as it
|
||||
builds out the cached Path entries.
|
||||
with the same paths. Significantly slower otherwise, as it builds
|
||||
out the cached Path entries.
|
||||
|
||||
To get a `Path` object resolved from the `PathScurry`, use
|
||||
`pw.cwd.resolve(path)`. Note that `Path.resolve` only takes a
|
||||
|
@ -452,8 +452,8 @@ object.
|
|||
Returns `undefined` if the entry does not exist, or if any error
|
||||
is encountered.
|
||||
|
||||
Note that some `Stats` data (such as `ino`, `dev`, and `mode`) will
|
||||
not be supplied. For those things, you'll need to call
|
||||
Note that some `Stats` data (such as `ino`, `dev`, and `mode`)
|
||||
will not be supplied. For those things, you'll need to call
|
||||
`fs.lstat` yourself.
|
||||
|
||||
#### `pw.lstatSync(entry = pw.cwd)`
|
||||
|
@ -500,8 +500,8 @@ Name of this file system entry.
|
|||
|
||||
**Important**: _always_ test the path name against any test
|
||||
string using the `isNamed` method, and not by directly comparing
|
||||
this string. Otherwise, unicode path strings that the system
|
||||
sees as identical will not be properly treated as the same path,
|
||||
this string. Otherwise, unicode path strings that the system sees
|
||||
as identical will not be properly treated as the same path,
|
||||
leading to incorrect behavior and possible security issues.
|
||||
|
||||
#### `path.isNamed(name: string): boolean`
|
||||
|
@ -516,6 +516,11 @@ pathname matches, due to unicode normalization mismatches.
|
|||
Always use this method instead of testing the `path.name`
|
||||
property directly.
|
||||
|
||||
#### `path.isCWD`
|
||||
|
||||
Set to true if this `Path` object is the current working
|
||||
directory of the `PathScurry` collection that contains it.
|
||||
|
||||
#### `path.getType()`
|
||||
|
||||
Returns the type of the Path object, `'File'`, `'Directory'`,
|
||||
|
|
1107
my-app/node_modules/path-scurry/dist/cjs/index.d.ts
generated
vendored
1107
my-app/node_modules/path-scurry/dist/cjs/index.d.ts
generated
vendored
File diff suppressed because it is too large
Load diff
1
my-app/node_modules/path-scurry/dist/cjs/index.d.ts.map
generated
vendored
1
my-app/node_modules/path-scurry/dist/cjs/index.d.ts.map
generated
vendored
File diff suppressed because one or more lines are too long
2018
my-app/node_modules/path-scurry/dist/cjs/index.js
generated
vendored
2018
my-app/node_modules/path-scurry/dist/cjs/index.js
generated
vendored
File diff suppressed because it is too large
Load diff
1
my-app/node_modules/path-scurry/dist/cjs/index.js.map
generated
vendored
1
my-app/node_modules/path-scurry/dist/cjs/index.js.map
generated
vendored
File diff suppressed because one or more lines are too long
3
my-app/node_modules/path-scurry/dist/cjs/package.json
generated
vendored
3
my-app/node_modules/path-scurry/dist/cjs/package.json
generated
vendored
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
"type": "commonjs"
|
||||
}
|
1107
my-app/node_modules/path-scurry/dist/mjs/index.d.ts
generated
vendored
1107
my-app/node_modules/path-scurry/dist/mjs/index.d.ts
generated
vendored
File diff suppressed because it is too large
Load diff
1
my-app/node_modules/path-scurry/dist/mjs/index.d.ts.map
generated
vendored
1
my-app/node_modules/path-scurry/dist/mjs/index.d.ts.map
generated
vendored
File diff suppressed because one or more lines are too long
1983
my-app/node_modules/path-scurry/dist/mjs/index.js
generated
vendored
1983
my-app/node_modules/path-scurry/dist/mjs/index.js
generated
vendored
File diff suppressed because it is too large
Load diff
1
my-app/node_modules/path-scurry/dist/mjs/index.js.map
generated
vendored
1
my-app/node_modules/path-scurry/dist/mjs/index.js.map
generated
vendored
File diff suppressed because one or more lines are too long
3
my-app/node_modules/path-scurry/dist/mjs/package.json
generated
vendored
3
my-app/node_modules/path-scurry/dist/mjs/package.json
generated
vendored
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
"type": "module"
|
||||
}
|
0
my-app/node_modules/path-scurry/node_modules/lru-cache/LICENSE
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/LICENSE
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/README.md
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/README.md
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/commonjs/index.d.ts
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/commonjs/index.d.ts
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/commonjs/index.d.ts.map
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/commonjs/index.d.ts.map
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/commonjs/index.js
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/commonjs/index.js
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/commonjs/index.js.map
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/commonjs/index.js.map
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/commonjs/package.json
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/commonjs/package.json
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/esm/index.d.ts
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/esm/index.d.ts
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/esm/index.d.ts.map
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/esm/index.d.ts.map
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/esm/index.js
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/esm/index.js
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/esm/index.js.map
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/esm/index.js.map
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/esm/package.json
generated
vendored
Executable file → Normal file
0
my-app/node_modules/path-scurry/node_modules/lru-cache/dist/esm/package.json
generated
vendored
Executable file → Normal file
13
my-app/node_modules/path-scurry/node_modules/lru-cache/package.json
generated
vendored
Executable file → Normal file
13
my-app/node_modules/path-scurry/node_modules/lru-cache/package.json
generated
vendored
Executable file → Normal file
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "lru-cache",
|
||||
"description": "A cache object that deletes the least-recently-used items.",
|
||||
"version": "10.2.0",
|
||||
"version": "10.2.2",
|
||||
"author": "Isaac Z. Schlueter <i@izs.me>",
|
||||
"keywords": [
|
||||
"mru",
|
||||
|
@ -11,8 +11,7 @@
|
|||
"sideEffects": false,
|
||||
"scripts": {
|
||||
"build": "npm run prepare",
|
||||
"prepare": "tshy",
|
||||
"postprepare": "bash fixup.sh",
|
||||
"prepare": "tshy && bash fixup.sh",
|
||||
"pretest": "npm run prepare",
|
||||
"presnap": "npm run prepare",
|
||||
"test": "tap",
|
||||
|
@ -35,8 +34,8 @@
|
|||
".": "./src/index.ts",
|
||||
"./min": {
|
||||
"import": {
|
||||
"types": "./dist/mjs/index.d.ts",
|
||||
"default": "./dist/mjs/index.min.js"
|
||||
"types": "./dist/esm/index.d.ts",
|
||||
"default": "./dist/esm/index.min.js"
|
||||
},
|
||||
"require": {
|
||||
"types": "./dist/commonjs/index.d.ts",
|
||||
|
@ -105,8 +104,8 @@
|
|||
},
|
||||
"./min": {
|
||||
"import": {
|
||||
"types": "./dist/mjs/index.d.ts",
|
||||
"default": "./dist/mjs/index.min.js"
|
||||
"types": "./dist/esm/index.d.ts",
|
||||
"default": "./dist/esm/index.min.js"
|
||||
},
|
||||
"require": {
|
||||
"types": "./dist/commonjs/index.d.ts",
|
||||
|
|
64
my-app/node_modules/path-scurry/package.json
generated
vendored
Executable file → Normal file
64
my-app/node_modules/path-scurry/package.json
generated
vendored
Executable file → Normal file
|
@ -1,19 +1,20 @@
|
|||
{
|
||||
"name": "path-scurry",
|
||||
"version": "1.10.1",
|
||||
"version": "1.11.1",
|
||||
"description": "walk paths fast and efficiently",
|
||||
"author": "Isaac Z. Schlueter <i@izs.me> (https://blog.izs.me)",
|
||||
"main": "./dist/cjs/index.js",
|
||||
"module": "./dist/mjs/index.js",
|
||||
"main": "./dist/commonjs/index.js",
|
||||
"type": "module",
|
||||
"exports": {
|
||||
"./package.json": "./package.json",
|
||||
".": {
|
||||
"import": {
|
||||
"types": "./dist/mjs/index.d.ts",
|
||||
"default": "./dist/mjs/index.js"
|
||||
"types": "./dist/esm/index.d.ts",
|
||||
"default": "./dist/esm/index.js"
|
||||
},
|
||||
"require": {
|
||||
"types": "./dist/cjs/index.d.ts",
|
||||
"default": "./dist/cjs/index.js"
|
||||
"types": "./dist/commonjs/index.d.ts",
|
||||
"default": "./dist/commonjs/index.js"
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -25,18 +26,17 @@
|
|||
"preversion": "npm test",
|
||||
"postversion": "npm publish",
|
||||
"prepublishOnly": "git push origin --follow-tags",
|
||||
"preprepare": "rm -rf dist",
|
||||
"prepare": "tsc -p tsconfig.json && tsc -p tsconfig-esm.json",
|
||||
"postprepare": "bash ./scripts/fixup.sh",
|
||||
"prepare": "tshy",
|
||||
"pretest": "npm run prepare",
|
||||
"presnap": "npm run prepare",
|
||||
"test": "c8 tap",
|
||||
"snap": "c8 tap",
|
||||
"test": "tap",
|
||||
"snap": "tap",
|
||||
"format": "prettier --write . --loglevel warn",
|
||||
"typedoc": "typedoc --tsconfig tsconfig-esm.json ./src/*.ts",
|
||||
"bench": "bash ./scripts/bench.sh"
|
||||
},
|
||||
"prettier": {
|
||||
"experimentalTernaries": true,
|
||||
"semi": false,
|
||||
"printWidth": 75,
|
||||
"tabWidth": 2,
|
||||
|
@ -47,31 +47,25 @@
|
|||
"arrowParens": "avoid",
|
||||
"endOfLine": "lf"
|
||||
},
|
||||
"tap": {
|
||||
"coverage": false,
|
||||
"node-arg": [
|
||||
"--no-warnings",
|
||||
"--loader",
|
||||
"ts-node/esm"
|
||||
],
|
||||
"ts": false
|
||||
},
|
||||
"devDependencies": {
|
||||
"@nodelib/fs.walk": "^1.2.8",
|
||||
"@types/node": "^20.1.4",
|
||||
"@types/tap": "^15.0.7",
|
||||
"@types/node": "^20.12.11",
|
||||
"c8": "^7.12.0",
|
||||
"eslint-config-prettier": "^8.6.0",
|
||||
"mkdirp": "^3.0.0",
|
||||
"prettier": "^2.8.3",
|
||||
"prettier": "^3.2.5",
|
||||
"rimraf": "^5.0.1",
|
||||
"tap": "^16.3.4",
|
||||
"ts-node": "^10.9.1",
|
||||
"typedoc": "^0.23.24",
|
||||
"typescript": "^5.0.4"
|
||||
"tap": "^18.7.2",
|
||||
"ts-node": "^10.9.2",
|
||||
"tshy": "^1.14.0",
|
||||
"typedoc": "^0.25.12",
|
||||
"typescript": "^5.4.3"
|
||||
},
|
||||
"tap": {
|
||||
"typecheck": true
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=16 || 14 >=14.17"
|
||||
"node": ">=16 || 14 >=14.18"
|
||||
},
|
||||
"funding": {
|
||||
"url": "https://github.com/sponsors/isaacs"
|
||||
|
@ -81,7 +75,15 @@
|
|||
"url": "git+https://github.com/isaacs/path-scurry"
|
||||
},
|
||||
"dependencies": {
|
||||
"lru-cache": "^9.1.1 || ^10.0.0",
|
||||
"lru-cache": "^10.2.0",
|
||||
"minipass": "^5.0.0 || ^6.0.2 || ^7.0.0"
|
||||
}
|
||||
},
|
||||
"tshy": {
|
||||
"selfLink": false,
|
||||
"exports": {
|
||||
"./package.json": "./package.json",
|
||||
".": "./src/index.ts"
|
||||
}
|
||||
},
|
||||
"types": "./dist/commonjs/index.d.ts"
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue