Skip to content
This repository was archived by the owner on Feb 2, 2021. It is now read-only.

Commit 92eec8c

Browse files
Add minimatch definition file
Add minimatch definition file to common lib.
1 parent e1e815f commit 92eec8c

File tree

1 file changed

+45
-0
lines changed

1 file changed

+45
-0
lines changed

definitions/minimatch.d.ts

+45
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
///<reference path="./node.d.ts"/>
2+
3+
declare module minimatch {
4+
export interface Options {
5+
debug?: boolean;
6+
nobrace?: boolean;
7+
noglobstar?: boolean;
8+
dot?: boolean;
9+
noext?: boolean;
10+
nonull?: boolean;
11+
nocase?: boolean;
12+
matchBase?: boolean;
13+
nocomment?: boolean;
14+
nonegate?: boolean;
15+
flipNegate?: boolean;
16+
}
17+
18+
export interface Minimatch {
19+
constructor(pattern: string, options: Options): Minimatch;
20+
pattern: string;
21+
options: Options;
22+
regexp: RegExp;
23+
set: any[][];
24+
negate: boolean;
25+
comment: boolean;
26+
empty: boolean;
27+
makeRe(): RegExp;
28+
match(path: string): boolean;
29+
}
30+
31+
export interface IMinimatch {
32+
(path: string, pattern: string, options?: Options): boolean;
33+
filter(pattern: string, options?: Options): (path: string) => boolean;
34+
match(fileList: string[], pattern: string, options?: Options): string[];
35+
makeRe(pattern: string, options?: Options): RegExp;
36+
37+
Minimatch: minimatch.Minimatch;
38+
}
39+
}
40+
41+
declare var minimatch: minimatch.IMinimatch;
42+
43+
declare module "minimatch" {
44+
export = minimatch;
45+
}

0 commit comments

Comments
 (0)