bodewig 01/05/08 02:35:32
Modified: . build.xml
src/etc/testcases/taskdefs get.xml
src/main/org/apache/tools/ant DesirableFilter.java
Project.java
src/main/org/apache/tools/ant/taskdefs XSLTProcess.java
src/main/org/apache/tools/ant/types Path.java
Log:
Assorted patches:
(1) make Ant JDK 1.4 aware
(2) improved <style> debugging
(3) bring DesirableFilter in line with defualt excludes
(4) use correct URL syntax in <get>'s unit test
(5) improve JavaDoc comments in Path.java
(6) description for test target in Ant's build file
Submitted by: Jesse Glick <Jesse.Glick@netbeans.com>
Revision Changes Path
1.150 +1 -1 jakarta-ant/build.xml
Index: build.xml
===================================================================
RCS file: /home/cvs/jakarta-ant/build.xml,v
retrieving revision 1.149
retrieving revision 1.150
diff -u -r1.149 -r1.150
--- build.xml 2001/05/04 08:03:44 1.149
+++ build.xml 2001/05/08 09:35:25 1.150
@@ -604,7 +604,7 @@
Run testcase
===================================================================
-->
- <target name="test" depends="run-tests"/>
+ <target name="test" depends="run-tests" description="--> run JUnit tests"/>
<target name="run-tests" depends="dump-info,compile-tests" if="junit.present">
1.4 +2 -2 jakarta-ant/src/etc/testcases/taskdefs/get.xml
Index: get.xml
===================================================================
RCS file: /home/cvs/jakarta-ant/src/etc/testcases/taskdefs/get.xml,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- get.xml 2001/03/08 15:17:19 1.3
+++ get.xml 2001/05/08 09:35:27 1.4
@@ -19,11 +19,11 @@
</target>
<target name="test5">
- <get src="http://www.apache.org" dest=""/>
+ <get src="http://www.apache.org/" dest=""/>
</target>
<target name="test6">
- <get src="http://www.apache.org" dest="get.tmp"/>
+ <get src="http://www.apache.org/" dest="get.tmp"/>
</target>
</project>
1.4 +10 -0 jakarta-ant/src/main/org/apache/tools/ant/DesirableFilter.java
Index: DesirableFilter.java
===================================================================
RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/DesirableFilter.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- DesirableFilter.java 2001/01/03 14:18:26 1.3
+++ DesirableFilter.java 2001/05/08 09:35:28 1.4
@@ -103,6 +103,16 @@
if (name.equals(".cvsignore")){
return false;
}
+
+ // CVS merge autosaves.
+ if (name.startsWith(".#")) {
+ return false;
+ }
+
+ // SCCS/CSSC/TeamWare:
+ if (name.equals("SCCS")) {
+ return false;
+ }
// default
return true;
1.57 +4 -1 jakarta-ant/src/main/org/apache/tools/ant/Project.java
Index: Project.java
===================================================================
RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/Project.java,v
retrieving revision 1.56
retrieving revision 1.57
diff -u -r1.56 -r1.57
--- Project.java 2001/03/19 13:05:45 1.56
+++ Project.java 2001/05/08 09:35:28 1.57
@@ -89,6 +89,7 @@
public static final String JAVA_1_1 = "1.1";
public static final String JAVA_1_2 = "1.2";
public static final String JAVA_1_3 = "1.3";
+ public static final String JAVA_1_4 = "1.4";
public static final String TOKEN_START = "@";
public static final String TOKEN_END = "@";
@@ -126,6 +127,8 @@
javaVersion = JAVA_1_2;
Class.forName("java.lang.StrictMath");
javaVersion = JAVA_1_3;
+ Class.forName("java.lang.CharSequence");
+ javaVersion = JAVA_1_4;
} catch (ClassNotFoundException cnfe) {
// swallow as we've hit the max class version that
// we have
@@ -348,7 +351,7 @@
throw new BuildException("Ant cannot work on Java 1.0");
}
- log("Detected Java Version: " + javaVersion, MSG_VERBOSE);
+ log("Detected Java version: " + javaVersion + " in: " + System.getProperty("java.home"),
MSG_VERBOSE);
log("Detected OS: " + System.getProperty("os.name"), MSG_VERBOSE);
}
1.21 +3 -1 jakarta-ant/src/main/org/apache/tools/ant/taskdefs/XSLTProcess.java
Index: XSLTProcess.java
===================================================================
RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/XSLTProcess.java,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -r1.20 -r1.21
--- XSLTProcess.java 2001/04/03 12:37:31 1.20
+++ XSLTProcess.java 2001/05/08 09:35:30 1.21
@@ -85,7 +85,7 @@
* @author <a href="mailto:rubys@us.ibm.com">Sam Ruby</a>
* @author <a href="mailto:russgold@acm.org">Russell Gold</a>
* @author <a href="stefan.bodewig@epost.de">Stefan Bodewig</a>
- * @version $Revision: 1.20 $ $Date: 2001/04/03 12:37:31 $
+ * @version $Revision: 1.21 $ $Date: 2001/05/08 09:35:30 $
*/
public class XSLTProcess extends MatchingTask {
@@ -330,6 +330,8 @@
try {
setProcessor("xalan");
} catch (Throwable e3) {
+ e2.printStackTrace();
+ e3.printStackTrace();
throw new BuildException(e1);
}
}
1.15 +4 -4 jakarta-ant/src/main/org/apache/tools/ant/types/Path.java
Index: Path.java
===================================================================
RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/types/Path.java,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- Path.java 2001/01/12 14:08:51 1.14
+++ Path.java 2001/05/08 09:35:31 1.15
@@ -106,7 +106,7 @@
/**
- * Helper class, holds the nested <pathelement> values.
+ * Helper class, holds the nested <code><pathelement></code>
values.
*/
public class PathElement {
private String[] parts;
@@ -186,7 +186,7 @@
}
/**
- * Creates the nested <pathelement> element.
+ * Creates the nested <code><pathelement></code> element.
*/
public PathElement createPathElement() throws BuildException {
if (isReference()) {
@@ -198,7 +198,7 @@
}
/**
- * Adds a nested <fileset> element.
+ * Adds a nested <code><fileset></code> element.
*/
public void addFileset(FileSet fs) throws BuildException {
if (isReference()) {
@@ -209,7 +209,7 @@
}
/**
- * Creates a nested <path> element.
+ * Creates a nested <code><path></code> element.
*/
public Path createPath() throws BuildException {
if (isReference()) {
|