ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sascha Ernst <sascha.er...@living-e.com>
Subject problems with empty directories and copy task
Date Mon, 01 Mar 2010 14:35:30 GMT
Hello,

I have a problem with a fileset/patternset and a copy task.

In the structure I'd like to copy there are (besides "normal" folders and files)

-          Empty directories

-          OS-specific folders

I'd like to copy everything (incl. the empty directories) but NOT the OS-specific folders
not matching
the desired OS-architecture.

Currently my copy-task looks like this (the ignore.<os-arch>-properties tell which OS-architecture
to ignore ):

                <patternset id="os.stuff.to.ignore">
                  <exclude name="**/win-i386/**/*" if="ignore.win-i386" />
                  <exclude name="**/win-amd64/**/*" if="ignore.win-amd64" />
                  <exclude name="**/solaris-x86/**/*" if="ignore.solaris-x86" />
                  <exclude name="**/solaris-amd64/**/*" if="ignore.solaris-amd64" />
                  <exclude name="**/linux-i386/**/*" if="ignore.linux-i386" />
                  <exclude name="**/linux-amd64/**/*" if="ignore.linux-amd64" />
                  <exclude name="**/solaris-sparc/**/*" if="ignore.solaris-sparc" />
                </patternset>

                <copy todir="${bin.dir}/../.."
                      overwrite="true"
                                 includeEmptyDirs="true"
                                 failonerror="true"
                                 verbose="true">
                  <fileset dir="./new">
                   <include name="**/*" />
                   <patternset refid="os.stuff.to.ignore"/>
                  </fileset>
                </copy>

It works fine BUT does not copy empty directories :(

Can someone tell me where I missed the point?

Regards

///Sascha///

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message