From 8402298bc51895e4106f1ab4d07939062b95a947 Mon Sep 17 00:00:00 2001
From: Stefan Bodewig
When these patterns are used in inclusion and exclusion, you have a powerful way to select just the files you want.
<copydir src="${src}" - dest="${dist}" - includes="**/images/*" - excludes="**/*.gif" />+
+<copy todir="${dist}" > + <fileset dir="${src}" + includes="**/images/*" + excludes="**/*.gif" + /> +</copy>
This copies all files in directories called "images", that are located in the directory tree "${src}" to the destination "${dist}", but excludes all "*.gif" files from the copy.
This example can also be expressed using nested elements as -
<copydir src="${src}" - dest="${dist}"> ++<copy todir="${dist}" > + <fileset dir="${src}" /> <include name="**/images/*"/> <exclude name="**/*.gif" /> - </copydir> + </fileset> +</copy>Default Excludes
@@ -1898,7 +1903,9 @@ that perform file copying operations through the Project commodity methods.Examples
<filter token="year" value="2000" /> - <copydir src="${src.dir}" dest="${dest.dir}"/>+ <copy todir="${dest.dir}"> + <fileset dir="${src.dir}" /> + </copy>
will copy recursively all the files from the src.dir directory into the dest.dir directory replacing all the occurencies of the string @year@ with 2000.