the problem with jar is that if you've signed it then it will be considered out of date since the manifest has changed. therefore, jar will create a new jar even though now classes in that jar where updated. thus, the signjar task will also execute since the new jar will be out of date with the touched file you've mentioned below. signjar works correctly with two files, the original jar file and the signed jar file. that is, it will not sign the jar if the signed jar is uptodate with the original jar file.
thanks for your help. mike -----Original Message----- From: Dominique Devienne [mailto:[EMAIL PROTECTED]] Sent: Friday, May 03, 2002 7:50 AM To: 'Ant Users List' Subject: RE: signing jar only if it has been updated Well, I'm not sure I understand... I didn't assume two files, especially not two jar files (the original and the signed), but was thinking the unsigned jar was modified/signed in place. The second file is an empty file created by <touch> (if needed) after you sign a jar to record the time the jar was last signed. By using <uptodate>, you can find out if your jar is more recent than this empty file, and only sign it if it is. So... 1) If the empty timestamp file doesn't exist, or is older that your jar, you need to sign your jar. 2) If the timestamp file exists, and is newer that your jar, you don't need to sign your jar. That simple! By maybe I didn't understand your problem correctly. --DD -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 02, 2002 6:15 PM To: [EMAIL PROTECTED] Subject: RE: signing jar only if it has been updated thanks for the response. this assumes there are two files. the original jar and the signed jar. i guess it wouldn't be possible with two seperate files. i was hoping that there was a feature that i may have missed to accomplish this with signjar. :) michael -----Original Message----- From: Dominique Devienne [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 02, 2002 2:15 PM To: 'Ant Users List' Subject: RE: signing jar only if it has been updated Right after you perform signjar, touch a file that acts as the timestamp for the last time you performed signjar. Then have your signjar target depend on a check-jar-up2date-4signjar target that uses <uptodate> between the jar and the timestamp file, setting a property if it need (or not) updating, and have the signjar target if/unless on that property. I'll leave the actual implementation to you ;-) Try it, and if you're stuck I can help some more, and someone not as lazy as me if going to provide you the full solution. --DD -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 02, 2002 3:17 PM To: [EMAIL PROTECTED] Subject: signing jar only if it has been updated would anyone out there know how to accomplish this? it seems that the signjar task signs a jar file regardless if it has changed. this takes quite a long time if the jar file is large. thanks, mike -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
