Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ignoreCustomPatterns execution requires ignoreCommonPatterns == false #3

Closed
julrichkieffer opened this issue Sep 14, 2017 · 2 comments

Comments

@julrichkieffer
Copy link

There's a logic error in index.js: for the opts.ignoreCustomPatterns to be assessed, opts.ignoreCommonPatterns must be false.

This has several unintended affects:

  • opts.ignoreCustomPatterns can't evaluate while also ignoring typical dev files (a regression)
  • this highlights a lack of suitable test scenarios
  • Docpad no longer behaves as documented since replacing it's code with a dependency on this package (a regression)
  • the API (opts object) implies that none, some, all "filters" will apply if set and tested against a given path. This issue assumes this as the intended behaviour. If not, the API is insufficiently documented
@balupton
Copy link
Member

balupton commented Jan 1, 2024

just spotted this, the upcoming v5 rewrite solves this

@balupton balupton closed this as completed Jan 1, 2024
@balupton
Copy link
Member

balupton commented Jan 1, 2024

for those interested, the problem is due to returning the result of the ignore, rather than just returning if the ignore was true - returning the result causes future checks to not be performed

https://github.com/bevry/ignorefs/blob/792d46df1b622c209397d914162480e3d47b3537/source/index.ts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants