Hmmm - I just had a thought. What does every one think about associating a mapper with each fileset ?
We could thus have something like <fileset dir="my/dir/"> <include name="**/*.classes" /> <mapper type="prefix" to="my/prefix"> </fileset> for prefixes. Or <fileset dir="my/dir/"> <include name="my-manifest.mf" /> <mapper type="merge" to="META-INF/MANIFEST.MF"> </fileset> for single files ? At 04:15 13/12/00 -0500, Rosen, Alex wrote: >That's a valid point, though I can definitely see this either way. If Ant >supported the prefix and/or fullpath attributes on all tasks where it made >sense (e.g. copy and move), would you still object? > >In any case, with Pete's latest change, both <filesets> and <prefixedfilesets> >can have these extra attributes in Zip tasks. This is either the best or worst >of both worlds, depending on how you look at it. It's being flexible about what >you accept - we tell users to use <prefixedfileset> when the use these >attributes, but if they forget, we'll take it anyway. I think this is probably >a bad idea, although if we change it, and you forget and accidentally say ><fileset prefix="foo">, you probably wouldn't get a very helpful message. (It >would tell you that <fileset> doesn't take a prefix attribute, instead of >suggesting that you need to use <prefixedfileset> to use the prefix attribute.) > >--Alex > >> -----Original Message----- >> From: Stefan Bodewig [mailto:[EMAIL PROTECTED] >> Sent: Wednesday, December 13, 2000 2:51 AM >> To: [EMAIL PROTECTED] >> Subject: Re: cvs commit: >> jakarta-ant/src/main/org/apache/tools/ant/taskdefs Jar.java War.java >> Zip.java >> >> >> <[EMAIL PROTECTED]> wrote: >> >> > Deprecated <prefixedfileset> element of war in favour of >> > normal <fileset> element in zip >> >> I don't like this. This means we have a <fileset> in <copy>, <move> >> and many other tasks that does not support the prefix attribute and a >> <fileset> in <zip>, <jar> and <war> that does. >> >> I.e. we have a fileset element in Ant buildfiles with two different >> attribute lists depending on context. This is not only giving us a >> headache when we want to provide a DTD, this will also confuse the >> user (is this a fileset that supports prefix or is it one that >> doesn't). >> >> Stefan > Cheers, Pete *-----------------------------------------------------* | "Faced with the choice between changing one's mind, | | and proving that there is no need to do so - almost | | everyone gets busy on the proof." | | - John Kenneth Galbraith | *-----------------------------------------------------*
