dcsimg
Using the JAR task
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Timothy_Bennett
Posted On:   Tuesday, July 16, 2002 07:26 AM

I've been using the JAR task in Ant for quite some time without problem. However, I need to do something slightly different with my jar file that I'm creating, and I can't figure out how to do it using Ant. Maybe someone can help? I need one file in my jar to be "uncompressed" -- just stored. All other files in my jar should be both "compressed" and stored. How do I do that in Ant? Here's what I tried: Unfortunately, the "update" option uncompresses ALL files that I had previously jar'd! Is this a bug in Ant, or the way it supposed to work? Any idea how to use Ant to do what I want it to do?    More>>

I've been using the JAR task in Ant for quite some time without problem. However, I need to do something slightly different with my jar file that I'm creating, and I can't figure out how to do it using Ant. Maybe someone can help?



I need one file in my jar to be "uncompressed" -- just stored. All other files in my jar should be both "compressed" and stored. How do I do that in Ant?



Here's what I tried:


			











Unfortunately, the "update" option uncompresses ALL files that I had previously jar'd! Is this a bug in Ant, or the way it supposed to work? Any idea how to use Ant to do what I want it to do?    <<Less

Re: Using the JAR task

Posted By:   Eugene_Kuleshov  
Posted On:   Tuesday, July 16, 2002 05:21 PM

I will not say that it is a bug. More likely it is a feature. Because there is not way to really update files within a zip/jar archive, jar (and Ant's jar task) creates the temporary file and copy all files from the original one and only update them if it is applicable. So, your case is just not supported.



I can suggest you to write a custom task to add a single unpacked file into archive. It is easy.
About | Sitemap | Contact