-
Notifications
You must be signed in to change notification settings - Fork 413
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
Add ability to exclude directories in addition to files. #542
Conversation
…e: ['Vendor/']`. Related issue: realm#503
@@ -409,7 +409,7 @@ def self.filter_excluded_files(json) | |||
excluded_files = Config.instance.excluded_files | |||
json.map do |doc| | |||
key = doc.keys.first | |||
doc[key] unless excluded_files.include?(Pathname(key)) | |||
doc[key] unless excluded_files.detect{|file| key.include? file.to_s} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not use File.fnmatch ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no particular reason. Just didn't think of it :) I can make the change if you'd like.
There are a few easy rubocop style violations that need to be addressed: https://travis-ci.org/realm/jazzy/builds/126147351 |
Thanks @jpsim . Updated. |
Thanks! |
Add ability to exclude directories in addition to files.
E.g.
exclude: ['Vendor/*']
Related issue: #503