DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16890>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16890 Available accepting nested FileSets Summary: Available accepting nested FileSets Product: Ant Version: 1.6Alpha (nightly) Platform: Other OS/Version: Other Status: NEW Severity: Enhancement Priority: Other Component: Core tasks AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] For your consideration, a patch that would add support for nested <fileset> inside of <available> conditions, where the property is set to true if the <fileset> includes any files. For example (my actual desired usage): <available property="cactus.test.cases"> <fileset dir="${test.src.dir}"> <include name="**/cactus/**"/> </fileset> </available> We have a common build target that runs tests for several modules. Some modules have cactus test cases, others don't. (Cactus test cases are stored in separate folder heirarchy). With this patch, I can easily condition the running of cactus targets on the fly based on whether any files are included in a particular module. The alternative that I currently use is copy the files described by the fileset through a merge mapper and then check for the resultant file. This works fine, but its slow on the modules that have lots of cactus tests: <copy todir="${build.test.classes}"> <fileset dir="${test.src.dir}"> <include name="**/cactus/**/*.java"/> </fileset> <mapper type="merge" to="cactus.fileset"/> </copy> <available property="cactus.testcases" file="${build.test.classes}/cactus.fileset"/> I'm open to other alternatives as well.