You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Implement the `ignoreFile` option and rewrite the `ignore` option behaviour.
Previously, we used `glob`'s `ignore` option to pass an array of ignore rules to the library. This meant we'd get back a set of filtered files where ignore rules were already applied. However, `glob` does not support negated ignore rules, meaning ignore patterns like "ignore everything except file x" wouldn't work.
With this change, we introduce a new library to the project: [ignore](https://www.npmjs.com/package/ignore). It lets us add rules to a rule checker (regardless of if these rules come from a file or an array). We now first collect all files with `glob` and subsequently filter out the ones that are ignored by the specified ignore rules. This rule checker supports all rules as specified in `.gitignore` specs. Therefore, it also supports negated ignore rules.
0 commit comments