@vltpkg/which 0.0.0-0.1730239248325 → 0.0.0-0.1730724342581
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/README.md +13 -8
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,15 +1,20 @@
|
|
|
1
|
-
|
|
1
|
+

|
|
2
|
+
|
|
3
|
+
# @vltpkg/which
|
|
2
4
|
|
|
3
5
|
Like the unix `which` utility.
|
|
4
6
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
7
|
+
**[Usage](#usage)**
|
|
8
|
+
·
|
|
9
|
+
**[Options](#options)**
|
|
10
|
+
|
|
11
|
+
## Overview
|
|
12
|
+
|
|
13
|
+
Finds the first instance of a specified executable in the PATH environment variable. Does not cache the results, so `hash -r` is not needed when the PATH changes.
|
|
8
14
|
|
|
9
|
-
Port of the [`which`](http://npm.im/which) to a TypeScript hybrid
|
|
10
|
-
module.
|
|
15
|
+
Port of the [`which`](http://npm.im/which) to a TypeScript hybrid module.
|
|
11
16
|
|
|
12
|
-
##
|
|
17
|
+
## Usage
|
|
13
18
|
|
|
14
19
|
```js
|
|
15
20
|
import { which, whichSync } from '@vltpkg/which'
|
|
@@ -32,7 +37,7 @@ const resolvedOrNull = whichSync('node', { nothrow: true })
|
|
|
32
37
|
await which('node', { path: someOtherPath, pathExt: somePathExt })
|
|
33
38
|
```
|
|
34
39
|
|
|
35
|
-
##
|
|
40
|
+
## Options
|
|
36
41
|
|
|
37
42
|
You may pass an options object as the second argument.
|
|
38
43
|
|