Hello,
I want to copy a directory and apply a content filtering only to some files,
ie. a conditional filtering (eg. all xml files will be filtered and the
other files will be copied as it). Thanks to the documentation, copy and
filtering with include and exclude is quite clear. But it apply to all
files.
The common (maven and ant) workaround uses two copy tasks. One with include
"*.xml" and the filtering on, one with the exclude "*.xml" and the filtering
off. It's a bit cumbersome.
Does Gradle handles conditional filtering ? [1]
Thanks for your help^.
[1] For example :
task(type: Copy) {
from 'src/main/resources'
into buildDir
filter(* '**/*.txt'* , ...)
}