Skip to content

Commit 2af2623

Browse files
committed
fix(providers): enable "posix" micromatch option
1 parent 039a52c commit 2af2623

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

src/providers/provider.spec.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,8 @@ describe('Providers → Provider', () => {
103103
nobrace: false,
104104
nocase: false,
105105
noext: false,
106-
noglobstar: false
106+
noglobstar: false,
107+
posix: true
107108
};
108109

109110
const actual = provider.getMicromatchOptions();

src/providers/provider.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,8 @@ export default abstract class Provider<T> {
4646
nobrace: !this._settings.braceExpansion,
4747
nocase: !this._settings.caseSensitiveMatch,
4848
noext: !this._settings.extglob,
49-
noglobstar: !this._settings.globstar
49+
noglobstar: !this._settings.globstar,
50+
posix: true
5051
};
5152
}
5253
}

src/types/index.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@ export type ErrorFilterFunction = fsWalk.ErrorFilterFunction;
2424
export type EntryFilterFunction = fsWalk.EntryFilterFunction;
2525
export type DeepFilterFunction = fsWalk.DeepFilterFunction;
2626
export type EntryTransformerFunction = (entry: Entry) => EntryItem;
27-
export type MicromatchOptions = micromatch.Options;
27+
export type MicromatchOptions = micromatch.Options & {
28+
posix?: boolean;
29+
};
2830

2931
export type FileSystemAdapter = fsWalk.FileSystemAdapter;

0 commit comments

Comments
 (0)