ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jacob Kjome <>
Subject Re[2]: Question about copying files
Date Mon, 26 Aug 2002 18:51:08 GMT
Hello Dominique,

Is there a technique works with Ant-1.4.1 that will do this?  If so, I
imagine it is more verbose, but I'd like to do this *and* keep
Ant-1.4.1 compatibility.

Any suggestions?


Monday, August 26, 2002, 10:11:47 AM, you wrote:

DD> I believe this can be achieved by clever use of the new <selectors>
DD> sub-elements of <fileset>. Check it out in the doc. --DD

DD> -----Original Message-----
DD> From: Christian Cryder [] 
DD> Sent: Monday, August 26, 2002 10:04 AM
DD> To: Ant-User
DD> Subject: Question about copying files

DD> Hi folks,

DD> I need to copy sample files sometimes, and I currently do it like this:

DD>     <copy todir="${build.dir}" >
DD>         <fileset dir="${build.dir}" />
DD>         <mapper type="glob" from="sample.*" to="*" />
DD>     </copy>

DD> What I need to know how to do, is to only copy files that _do not already
DD> exist_.

DD> In other words, if I have the following files in a directory:

DD>   sample.foo1 (unchanged, foo1 exists)
DD>   sample.foo2 (changed, foo2 exists)
DD>   sample.foo3 (new, foo3 does not exist)

DD> only foo3 should be copied.

DD> Suggestions?

DD> tia,
DD> Christian
DD> ----------------------------------------------
DD> Christian Cryder []
DD> Internet Architect,
DD> Barracuda -
DD> ----------------------------------------------
DD> "Coffee? I could quit anytime, just not today"

DD> --
DD> To unsubscribe, e-mail:   <>
DD> For additional commands, e-mail: <>

DD> --
DD> To unsubscribe, e-mail:   <>
DD> For additional commands, e-mail: <>

Best regards,

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message