peterreilly 2004/05/17 03:18:30
Modified: src/main/org/apache/tools/ant/taskdefs Tag: ANT_16_BRANCH
SignJar.java
Log:
sync
Revision Changes Path
No revision
No revision
1.31.2.5 +8 -5 ant/src/main/org/apache/tools/ant/taskdefs/SignJar.java
Index: SignJar.java
===================================================================
RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/SignJar.java,v
retrieving revision 1.31.2.4
retrieving revision 1.31.2.5
diff -u -r1.31.2.4 -r1.31.2.5
--- SignJar.java 9 Mar 2004 17:01:34 -0000 1.31.2.4
+++ SignJar.java 17 May 2004 10:18:30 -0000 1.31.2.5
@@ -30,14 +30,11 @@
import org.apache.tools.ant.util.JavaEnvUtils;
/**
- * Signs jar or zip files with the javasign command line tool. The
+ * Signs JAR or ZIP files with the javasign command line tool. The
* tool detailed dependency checking: files are only signed if they
* are not signed. The <tt>signjar</tt> attribute can point to the file to
* generate; if this file exists then
* its modification date is used as a cue as to whether to resign any JAR
file.
- * <br>
- * <strong>Note:</strong> Requires Java 1.2 or later. </p>
-
*
* @since Ant 1.1
* @ant.task category="java"
@@ -299,7 +296,7 @@
cmd.createArg().setValue(alias);
- log("Signing Jar : " + jarSource.getAbsolutePath());
+ log("Signing JAR: " + jarSource.getAbsolutePath());
cmd.setFailonerror(true);
cmd.setTaskName(getTaskName());
cmd.execute();
@@ -333,6 +330,12 @@
return false;
}
+ /**
+ * test for a file being signed, by looking for a signature in the
META-INF
+ * directory
+ * @param file
+ * @return true if the file is signed
+ */
protected boolean isSigned(File file) {
final String SIG_START = "META-INF/";
final String SIG_END = ".SF";
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]