Skip to content

Commit

Permalink
expose minimatch 'debug' option
Browse files Browse the repository at this point in the history
  • Loading branch information
isaacs committed Apr 9, 2023
1 parent 10a3212 commit d024d3a
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/glob.ts
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,12 @@ export interface GlobOptions {
* http://npm.im/path-scurry for details about what can be overridden.
*/
fs?: FSOption

/**
* Just passed along to Minimatch. Note that this makes all pattern
* matching operations slower and *extremely* noisy.
*/
debug?: boolean
}

export type GlobOptionsWithFileTypesTrue = GlobOptions & {
Expand Down Expand Up @@ -452,6 +458,7 @@ export class Glob<Opts extends GlobOptions> implements GlobOptions {
optimizationLevel: 2,
platform: this.platform,
windowsPathsNoEscape: this.windowsPathsNoEscape,
debug: !!this.opts.debug,
}

const mms = this.pattern.map(p => new Minimatch(p, mmo))
Expand Down

0 comments on commit d024d3a

Please sign in to comment.