-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtypes.ts
More file actions
35 lines (34 loc) · 850 Bytes
/
types.ts
File metadata and controls
35 lines (34 loc) · 850 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
/**
* @file Public type surface for `bin/*` modules — the `WhichOptions` interface
* that callers pass to `which`, `whichSync`, `whichReal`, and
* `whichRealSync`. Pure types, no runtime side effects.
*/
/**
* Options for the which function.
*/
export interface WhichOptions {
/**
* If true, return all matches instead of just the first one.
*/
all?: boolean | undefined
/**
* If true, return null instead of throwing when no match is found.
*/
nothrow?: boolean | undefined
/**
* Path to search in.
*/
path?: string | undefined
/**
* Path separator character.
*/
pathExt?: string | undefined
/**
* Environment variables to use.
*/
env?: Record<string, string | undefined> | undefined
/**
* Current working directory for resolving relative paths.
*/
cwd?: string | undefined
}