-
Notifications
You must be signed in to change notification settings - Fork 69
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 a filter
field to rules and modules
#19
Comments
@olson-sean-k pointed out that "filter" is confusing. E.g. what does this mean:
Is
Also, should we make sure it's an error if we end up matching no files? I feel like it should definitely be an error if you try to add a literal filename that's not there. Git might take care of that for us, actually. |
I think |
Ok I didn't think this through though: What if the argument to |
It's been fairly common for me to use the
build
field to do something likewhen I want to export only part of a directory. That feels pretty hacky, and it will be very inconvenient in builds that need to support Windows or even just
cp -r
(Mac requires the-R
flag instead).It would be better to have some explicit filter field.
git add
supports * and ** globs natively, so it shouldn't be too much trouble to expose this throughCache.import_tree
.My guess is that it would make sense to apply the filter step after export, which means that filter paths would be relative to the export dir rather than relative to the module root. That would save the user from duplicating the export path in the filter spec. The order of application of rule fields would then be:
The text was updated successfully, but these errors were encountered: