cvs commit: ant/xdocs external.xml

2003-03-06 Thread bodewig
bodewig 2003/03/06 01:59:37

  Modified:docs external.html
   xdocsexternal.xml
  Log:
  Add pointer to generics compiler adapter.
  
  Submitted by: Matt Quail spud at madbean dot com
  
  Revision  ChangesPath
  1.93  +55 -0 ant/docs/external.html
  
  Index: external.html
  ===
  RCS file: /home/cvs/ant/docs/external.html,v
  retrieving revision 1.92
  retrieving revision 1.93
  diff -u -r1.92 -r1.93
  --- external.html 24 Feb 2003 15:02:15 -  1.92
  +++ external.html 6 Mar 2003 09:59:37 -   1.93
  @@ -2826,6 +2826,61 @@
   trtd bgcolor=#294563font color=#ffa name=Compiler 
ImplementationsstrongCompiler Implementations/strong/a/font/td/tr
 /table
 br/
  +  a name=Generics (JSR14) Early-Access Compiler Adapter/a
  +  table border=0 cellspacing=0 cellpadding=2 width=100%
  +trtd bgcolor=#4C6C8F
  +  font color=#ff face=arial,helvetica,sanserif
  +strongGenerics (JSR14) Early-Access Compiler Adapter/strong
  +  /font
  +/td/tr
  +  /table
  +pThis is an Ant compiler-adapter that allows you 
to use the
  +normal codelt;javacgt;/code task plus Sun's early-access
  +compiler to compile Generics-enabled Java code.  (This is only
  +necessary until JDK1.5 is released.)/p
  +  table class=ForrestTable 
cellspacing=1 cellpadding=4
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Compatibility:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Ant 1.5 and later
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  URL:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a 
href=http://www.madbean.com/blog/3/;http://www.madbean.com/blog/3//a
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Contact:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Matt Quail lt;spud[at]madbean[dot]comgt;
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  License:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Public Domain
  +  /td
  +  /tr
  +/table
  +br/
 a name=miniRMI lt;codegt;amp;lt;rmicamp;gt;lt;/codegt; 
implementation/a
 table border=0 cellspacing=0 cellpadding=2 width=100%
   trtd bgcolor=#4C6C8F
  
  
  
  1.70  +28 -0 ant/xdocs/external.xml
  
  Index: external.xml
  ===
  RCS file: /home/cvs/ant/xdocs/external.xml,v
  retrieving revision 1.69
  retrieving revision 1.70
  diff -u -r1.69 -r1.70
  --- external.xml  24 Feb 2003 15:02:15 -  1.69
  +++ external.xml  6 Mar 2003 09:59:37 -   1.70
  @@ -1340,6 +1340,34 @@
   /section
   
   section name=Compiler Implementations
  +
  +  subsection name=Generics (JSR14) Early-Access Compiler Adapter
  +
  +pThis is an Ant compiler-adapter that allows you to use the
  +normal codelt;javacgt;/code task plus Sun's early-access
  +compiler to compile Generics-enabled Java code.  (This is only
  +necessary until JDK1.5 is released.)/p
  +
  +table
  +  tr
  +thCompatibility:/th
  +tdAnt 1.5 and later/td
  +  /tr
  +  tr
  +thURL:/th
  +tda 
href=http://www.madbean.com/blog/3/;http://www.madbean.com/blog/3//a/td
  +  /tr
  +  tr
  +thContact:/th
  +tdMatt Quail lt;spud[at]madbean[dot]comgt;/td
  +  /tr
  +  tr
  +thLicense:/th
  +tdPublic Domain/td
  +  /tr
  +/table
  +  /subsection
  +
 subsection name=miniRMI 
lt;codegt;amp;lt;rmicamp;gt;lt;/codegt; implementation
   
   pminiRMI is a freeware opensource library that serves as a
  
  
  


cvs commit: ant/src/testcases/org/apache/tools/ant/taskdefs/optional/ssh ScpTest.java

2003-03-06 Thread bodewig
bodewig 2003/03/06 04:42:44

  Modified:.WHATSNEW build.xml
   docs/manual install.html optionaltasklist.html
   src/main/org/apache/tools/ant/taskdefs defaults.properties
  Added:   docs/manual/OptionalTasks scp.html
   src/main/org/apache/tools/ant/taskdefs/optional/ssh
AbstractSshMessage.java Directory.java
LogListener.java Scp.java ScpFromMessage.java
ScpToMessage.java
   src/testcases/org/apache/tools/ant/taskdefs/optional/ssh
ScpTest.java
  Log:
  scp
  
  Submitted by: charliehubbard76 at yahoo dot com
  
  Revision  ChangesPath
  1.361 +3 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.360
  retrieving revision 1.361
  diff -u -r1.360 -r1.361
  --- WHATSNEW  6 Mar 2003 12:04:59 -   1.360
  +++ WHATSNEW  6 Mar 2003 12:42:43 -   1.361
  @@ -157,6 +157,9 @@
   * The javadoc task tag subelement has been enhanced to allow files
 with tag mappings to be used.
   
  +* New task scp that supports file transfers over SSH.  Requires
  +  jsch, a BSD licensed SSH library that can be found at 
  +  http://www.jcraft.com/jsch/index.html
   
   Changes from Ant 1.5.1 to Ant 1.5.2
   =
  
  
  
  1.354 +22 -1 ant/build.xml
  
  Index: build.xml
  ===
  RCS file: /home/cvs/ant/build.xml,v
  retrieving revision 1.353
  retrieving revision 1.354
  diff -u -r1.353 -r1.354
  --- build.xml 26 Feb 2003 13:06:06 -  1.353
  +++ build.xml 6 Mar 2003 12:42:43 -   1.354
  @@ -155,7 +155,10 @@
   /or
 /selector
 selector id=needs.jdk1.4+
  -filename name=${regexp.package}/Jdk14Regexp*/
  +or
  +  filename name=${regexp.package}/Jdk14Regexp*/
  +  filename name=${optional.package}/ssh/*/
  +/or
 /selector
   
 !-- classes that should be present in Sun based JVMs, but not in
  @@ -289,6 +292,9 @@
 selector id=needs.swing
   filename name=${optional.package}/splash/*/
 /selector
  +  selector id=needs.jsch
  +filename name=${optional.package}/ssh/*/
  +  /selector
 patternset id=onlinetests
   exclude name=**/GetTest.java if=offline/
   exclude name=**/SignJarTest.java if=offline/
  @@ -543,6 +549,9 @@
   available property=beanshell.present
  classname=bsh.StringUtil
  classpathref=classpath/
  +available property=jsch.present
  +   classname=com.jcraft.jsch.Session
  +   classpathref=classpath/
 /target
   
   
  @@ -625,6 +634,7 @@
   selector refid=needs.jai unless=jai.present/
   selector refid=needs.jdepend unless=jdepend.present/
   selector refid=needs.swing  unless=swing.present/
  +selector refid=needs.jsch unless=jsch.present/
 /or
   /not
 /selector
  @@ -792,6 +802,7 @@
   selector refid=needs.jai/
   selector refid=needs.jdepend/
   selector refid=needs.swing/
  +selector refid=needs.jsch/
 /or
   /not
 /and
  @@ -949,6 +960,13 @@
   selector refid=needs.weblogic.server/
 /or
   /jar
  +
  +jar destfile=${build.lib}/${optional.jars.prefix}-jsch.jar
  + basedir=${build.classes}
  + manifest=${manifest.tmp}
  +  selector refid=needs.jsch/
  +/jar
  +
 /target
   
 !--   Creates jar of test utility classes --
  @@ -1616,6 +1634,9 @@
 --
 exclude name=${ant.package}/taskdefs/AbstractCvsTaskTest.java
  unless=have.cvs/
  +
  +  !-- test needs special setup --
  +  exclude name=${optional.package}/ssh/ScpTest.java/
   /fileset
 /batchtest
   /junit
  
  
  
  1.47  +6 -0  ant/docs/manual/install.html
  
  Index: install.html
  ===
  RCS file: /home/cvs/ant/docs/manual/install.html,v
  retrieving revision 1.46
  retrieving revision 1.47
  diff -u -r1.46 -r1.47
  --- install.html  24 Feb 2003 08:25:19 -  1.46
  +++ install.html  6 Mar 2003 12:42:43 -   1.47
  @@ -418,6 +418,12 @@
   target=_tophttp://gump.covalent.net/jars/latest/xml-commons//a
   for a nightly snapshot./td
 /tr
  +  tr
  +tdjsch.jar/td
  +tdscp task/td
  +tda href=http://www.jcraft.com/jsch/index.html;
  +target=_tophttp://www.jcraft.com/jsch/index.html/a/td
  +  /tr
   /table
   br
   hr
  
  
  
  1.35  +1 -0  ant/docs/manual/optionaltasklist.html
  
  Index: optionaltasklist.html
  ===
  RCS file

cvs commit: ant/src/main/org/apache/tools/ant/taskdefs Zip.java

2003-03-07 Thread bodewig
bodewig 2003/03/07 00:07:18

  Modified:src/main/org/apache/tools/ant/taskdefs Zip.java
  Log:
  Set file mode correctly for files read from zipfilesets.
  
  PR: 17648
  Submitted by:  Antoine Levy-Lambert
  
  Revision  ChangesPath
  1.99  +1 -1  ant/src/main/org/apache/tools/ant/taskdefs/Zip.java
  
  Index: Zip.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Zip.java,v
  retrieving revision 1.98
  retrieving revision 1.99
  diff -u -r1.98 -r1.99
  --- Zip.java  26 Feb 2003 09:57:01 -  1.98
  +++ Zip.java  7 Mar 2003 08:07:17 -   1.99
  @@ -538,7 +538,7 @@
   prefix = zfs.getPrefix();
   fullpath = zfs.getFullpath();
   dirMode = zfs.getDirMode();
  -fileMode = zfs.getDirMode();
  +fileMode = zfs.getFileMode();
   }
   
   if (prefix.length()  0  fullpath.length()  0) {
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh AbstractSshMessage.java Scp.java ScpFromMessage.java ScpToMessage.java

2003-03-10 Thread bodewig
bodewig 2003/03/10 02:05:43

  Modified:src/main/org/apache/tools/ant/taskdefs/optional/ssh
AbstractSshMessage.java Scp.java
ScpFromMessage.java ScpToMessage.java
  Log:
  Upgrade to jsch-0.1.2
  
  Revision  ChangesPath
  1.2   +4 -3  
ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/AbstractSshMessage.java
  
  Index: AbstractSshMessage.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/AbstractSshMessage.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AbstractSshMessage.java   6 Mar 2003 12:42:44 -   1.1
  +++ AbstractSshMessage.java   10 Mar 2003 10:05:43 -  1.2
  @@ -54,9 +54,10 @@
   
   package org.apache.tools.ant.taskdefs.optional.ssh;
   
  -import com.jcraft.jsch.Session;
   import com.jcraft.jsch.Channel;
   import com.jcraft.jsch.ChannelExec;
  +import com.jcraft.jsch.JSchException;
  +import com.jcraft.jsch.Session;
   
   import java.io.IOException;
   import java.io.OutputStream;
  @@ -76,7 +77,7 @@
   this.session = session;
   }
   
  -protected Channel openExecChannel( String command ) {
  +protected Channel openExecChannel( String command ) throws JSchException 
{
   ChannelExec channel = (ChannelExec) session.openChannel( exec );
   channel.setCommand( command );
   
  @@ -97,7 +98,7 @@
   } while (b  0);
   }
   
  -public abstract void execute() throws IOException;
  +public abstract void execute() throws IOException, JSchException;
   
   public void setLogListener( LogListener aListener ) {
   listener = aListener;
  
  
  
  1.3   +2 -2  
ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/Scp.java
  
  Index: Scp.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/Scp.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- Scp.java  7 Mar 2003 14:53:36 -   1.2
  +++ Scp.java  10 Mar 2003 10:05:43 -  1.3
  @@ -201,7 +201,7 @@
   if( failOnError ) {
   throw new BuildException(e);
   } else {
  -e.printStackTrace();
  +log(Caught exception:  + e.getMessage(), Project.MSG_ERR);
   }
   }
   }
  @@ -317,7 +317,7 @@
   }
   
   private Directory createDirectory( FileSet set ) {
  -DirectoryScanner scanner = set.getDirectoryScanner( project );
  +DirectoryScanner scanner = set.getDirectoryScanner( getProject() );
   Directory root = new Directory( scanner.getBasedir() );
   String[] files = scanner.getIncludedFiles();
   for (int j = 0; j  files.length; j++) {
  
  
  
  1.2   +1 -1  
ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/ScpFromMessage.java
  
  Index: ScpFromMessage.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/ScpFromMessage.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ScpFromMessage.java   6 Mar 2003 12:42:44 -   1.1
  +++ ScpFromMessage.java   10 Mar 2003 10:05:43 -  1.2
  @@ -76,7 +76,7 @@
   this.isRecursive = recursive;
   }
   
  -public void execute() throws IOException {
  +public void execute() throws IOException, JSchException {
   String command = scp -f ;
   if( isRecursive )
   command += -r ;
  
  
  
  1.2   +5 -4  
ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/ScpToMessage.java
  
  Index: ScpToMessage.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/ScpToMessage.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ScpToMessage.java 6 Mar 2003 12:42:44 -   1.1
  +++ ScpToMessage.java 10 Mar 2003 10:05:43 -  1.2
  @@ -54,8 +54,9 @@
   
   package org.apache.tools.ant.taskdefs.optional.ssh;
   
  -import com.jcraft.jsch.Session;
   import com.jcraft.jsch.Channel;
  +import com.jcraft.jsch.Session;
  +import com.jcraft.jsch.JSchException;
   
   import java.io.*;
   import java.util.*;
  @@ -85,7 +86,7 @@
   this.remotePath = aRemotePath;
   }
   
  -public void execute() throws IOException {
  +public void execute() throws IOException, JSchException {
   if( directoryList != null ) {
   doMultipleTransfer();
   }
  @@ -95,7 +96,7 @@
   log(done.\n);
   }
   
  -private void doSingleTransfer() throws IOException {
  +private void doSingleTransfer() throws IOException, JSchException

cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/dotnet NetCommand.java

2003-03-10 Thread bodewig
bodewig 2003/03/10 02:11:19

  Modified:src/main/org/apache/tools/ant/taskdefs/optional/dotnet
NetCommand.java
  Log:
  2003
  
  Revision  ChangesPath
  1.19  +1 -1  
ant/src/main/org/apache/tools/ant/taskdefs/optional/dotnet/NetCommand.java
  
  Index: NetCommand.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/dotnet/NetCommand.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- NetCommand.java   10 Mar 2003 08:02:24 -  1.18
  +++ NetCommand.java   10 Mar 2003 10:11:19 -  1.19
  @@ -1,7 +1,7 @@
   /*
* The Apache Software License, Version 1.1
*
  - * Copyright (c) 2000-2002 The Apache Software Foundation.  All rights
  + * Copyright (c) 2000-2003 The Apache Software Foundation.  All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/dotnet CSharp.java VisualBasicCompile.java

2003-03-11 Thread bodewig
bodewig 2003/03/11 00:28:39

  Modified:src/main/org/apache/tools/ant/taskdefs/optional/dotnet
CSharp.java VisualBasicCompile.java
  Log:
  2003
  
  Revision  ChangesPath
  1.31  +1 -1  
ant/src/main/org/apache/tools/ant/taskdefs/optional/dotnet/CSharp.java
  
  Index: CSharp.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/dotnet/CSharp.java,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -r1.30 -r1.31
  --- CSharp.java   11 Mar 2003 06:07:37 -  1.30
  +++ CSharp.java   11 Mar 2003 08:28:38 -  1.31
  @@ -1,7 +1,7 @@
   /*
* The Apache Software License, Version 1.1
*
  - * Copyright (c) 2001-2002 The Apache Software Foundation.  All rights
  + * Copyright (c) 2001-2003 The Apache Software Foundation.  All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
  
  
  
  1.4   +1 -1  
ant/src/main/org/apache/tools/ant/taskdefs/optional/dotnet/VisualBasicCompile.java
  
  Index: VisualBasicCompile.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/dotnet/VisualBasicCompile.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- VisualBasicCompile.java   11 Mar 2003 06:07:37 -  1.3
  +++ VisualBasicCompile.java   11 Mar 2003 08:28:38 -  1.4
  @@ -1,7 +1,7 @@
   /*
* The Apache Software License, Version 1.1
*
  - * Copyright (c) 2001-2002 The Apache Software Foundation.  All rights
  + * Copyright (c) 2001-2003 The Apache Software Foundation.  All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
  
  
  


cvs commit: ant build.xml

2003-03-11 Thread bodewig
bodewig 2003/03/11 00:41:36

  Modified:.build.xml
  Log:
  .NET tests need .NET apps
  
  Revision  ChangesPath
  1.355 +2 -0  ant/build.xml
  
  Index: build.xml
  ===
  RCS file: /home/cvs/ant/build.xml,v
  retrieving revision 1.354
  retrieving revision 1.355
  diff -u -r1.354 -r1.355
  --- build.xml 6 Mar 2003 12:42:43 -   1.354
  +++ build.xml 11 Mar 2003 08:41:35 -  1.355
  @@ -1612,6 +1612,8 @@
 !-- misc oneoff tests --
 exclude name=${optional.package}/WsdlToDotnetTest.java
  unless=dotnetapps.found/
  +  exclude name=${optional.package}/DotnetTest.java
  +   unless=dotnetapps.found/
   
 !--  These tests only passes if testcases and Ant classes have
 been loaded by the same classloader - will throw
  
  
  


cvs commit: ant/src/testcases/org/apache/tools/ant/types/selectors BaseSelectorTest.java FilenameSelectorTest.java

2003-03-11 Thread bodewig
bodewig 2003/03/11 01:26:44

  Modified:src/etc/testcases/taskdefs bunzip2.xml bzip2.xml
   src/etc/testcases/types selectors.xml
   src/testcases/org/apache/tools/ant/taskdefs BUnzip2Test.java
BZip2Test.java
   src/testcases/org/apache/tools/ant/types/selectors
BaseSelectorTest.java FilenameSelectorTest.java
  Added:   src/etc/testcases/taskdefs/expected asf-logo-huge.tar.gz
  Removed: src/etc/testcases/taskdefs/expected asf-logo-huge.tar
  Log:
  Save some (mega)bytes
  
  Revision  ChangesPath
  1.4   +5 -1  ant/src/etc/testcases/taskdefs/bunzip2.xml
  
  Index: bunzip2.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/taskdefs/bunzip2.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- bunzip2.xml   23 Jun 2002 01:20:01 -  1.3
  +++ bunzip2.xml   11 Mar 2003 09:26:39 -  1.4
  @@ -2,12 +2,16 @@
   
   project basedir=. default=cleanup
   
  -  target name=realTest depends=cleanup
  +  target name=realTest
   bunzip2 src=expected/asf-logo-huge.tar.bz2 dest=asf-logo-huge.tar /
 /target
   
 target name=cleanup
   delete file=asf-logo-huge.tar /
  +delete file=expected/asf-logo-huge.tar /
 /target
   
  +  target name=prepare
  +gunzip src=expected/asf-logo-huge.tar.gz/
  +  /target
   /project
  
  
  
  1.5   +6 -2  ant/src/etc/testcases/taskdefs/bzip2.xml
  
  Index: bzip2.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/taskdefs/bzip2.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- bzip2.xml 23 Jun 2002 01:20:01 -  1.4
  +++ bzip2.xml 11 Mar 2003 09:26:40 -  1.5
  @@ -2,11 +2,11 @@
   
   project basedir=. default=cleanup
   
  -  target name=realTest depends=cleanup
  +  target name=realTest
   bzip2 src=expected/asf-logo-huge.tar zipfile=asf-logo-huge.tar.bz2 
/
 /target
   
  -  target name=testDateCheck depends=cleanup
  +  target name=testDateCheck
   touch file=asf-logo.gif.bz2/
   bzip2 src=../asf-logo.gif zipfile=asf-logo.gif.bz2 /
 /target
  @@ -14,6 +14,10 @@
 target name=cleanup
   delete file=asf-logo-huge.tar.bz2 /
   delete file=asf-logo.gif.bz2 /
  +delete file=expected/asf-logo-huge.tar/
 /target
   
  +  target name=prepare
  +gunzip src=expected/asf-logo-huge.tar.gz/
  +  /target
   /project
  
  
  
  1.1  
ant/src/etc/testcases/taskdefs/expected/asf-logo-huge.tar.gz
  
Binary file
  
  
  1.4   +4 -4  ant/src/etc/testcases/types/selectors.xml
  
  Index: selectors.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/types/selectors.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- selectors.xml 9 Jul 2002 21:05:57 -   1.3
  +++ selectors.xml 11 Mar 2003 09:26:44 -  1.4
  @@ -26,8 +26,8 @@
   tofile=${test.dir}/zip/asf-logo.gif.zip /
   copy file=${etc.dir}/taskdefs/expected/asf-logo.gif.tar
   tofile=${test.dir}/tar/asf-logo.gif.tar /
  -copy file=${etc.dir}/taskdefs/expected/asf-logo-huge.tar
  -tofile=${test.dir}/tar/asf-logo-huge.tar /
  +copy file=${etc.dir}/taskdefs/expected/asf-logo-huge.tar.gz
  +tofile=${test.dir}/tar/asf-logo-huge.tar.gz /
   copy file=${etc.dir}/taskdefs/expected/asf-logo.gif.tar.gz
   tofile=${test.dir}/tar/gz/asf-logo.gif.tar.gz /
   copy file=${etc.dir}/taskdefs/expected/asf-logo.gif.tar.bz2
  @@ -51,7 +51,7 @@
   datetime=05/10/2002 2:30 PM/
   touch file=${test.dir}/tar/asf-logo.gif.tar
   datetime=05/10/2002 2:29 PM/
  -touch file=${test.dir}/tar/asf-logo-huge.tar
  +touch file=${test.dir}/tar/asf-logo-huge.tar.gz
   datetime=05/10/2002 2:29 AM/
 /target
   
  @@ -72,7 +72,7 @@
   sleep seconds=3/
   touch file=${mirror.dir}/tar/asf-logo.gif.tar/
   sleep seconds=2/
  -touch file=${mirror.dir}/tar/asf-logo-huge.tar/
  +touch file=${mirror.dir}/tar/asf-logo-huge.tar.gz/
   touch file=${mirror.dir}/tar/gz/asf-logo.gif.tar.gz/
   touch file=${mirror.dir}/tar/bz2/asf-logo.gif.tar.bz2/
   touch file=${mirror.dir}/tar/bz2/asf-logo-huge.tar.bz2/
  
  
  
  1.7   +3 -2  
ant/src/testcases/org/apache/tools/ant/taskdefs/BUnzip2Test.java
  
  Index: BUnzip2Test.java
  ===
  RCS file: 
/home/cvs/ant/src/testcases/org/apache/tools/ant/taskdefs/BUnzip2Test.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- BUnzip2Test.java  7 Mar 2003 11:23:11 -   1.6
  +++ BUnzip2Test.java  11 Mar 2003 09:26:44 -

cvs commit: ant/src/testcases/org/apache/tools/ant/taskdefs/optional/sitraka ClassPathLoaderTest.java

2003-03-11 Thread bodewig
bodewig 2003/03/11 02:30:15

  Modified:src/testcases/org/apache/tools/ant/taskdefs/optional/sitraka
ClassPathLoaderTest.java
  Log:
  Make test more robust.  In particular - make it pass on Mac OS X.
  
  Revision  ChangesPath
  1.3   +6 -4  
ant/src/testcases/org/apache/tools/ant/taskdefs/optional/sitraka/ClassPathLoaderTest.java
  
  Index: ClassPathLoaderTest.java
  ===
  RCS file: 
/home/cvs/ant/src/testcases/org/apache/tools/ant/taskdefs/optional/sitraka/ClassPathLoaderTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- ClassPathLoaderTest.java  10 Feb 2003 14:14:54 -  1.2
  +++ ClassPathLoaderTest.java  11 Mar 2003 10:30:15 -  1.3
  @@ -1,7 +1,7 @@
   /*
* The Apache Software License, Version 1.1
*
  - * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * Copyright (c) 2001,2003 The Apache Software Foundation.  All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
  @@ -57,6 +57,7 @@
   import java.io.File;
   
   import junit.framework.TestCase;
  +import org.apache.tools.ant.types.Path;
   import 
org.apache.tools.ant.taskdefs.optional.sitraka.bytecode.ClassPathLoader;
   
   /**
  @@ -71,9 +72,10 @@
   
   public void testgetClasses() throws Exception {
   // good performance test...load all classes in rt.jar
  -String path = System.getProperty(java.home) + File.separator + 
lib/rt.jar;
  -ClassPathLoader cl = new ClassPathLoader(path);
  - Hashtable map = cl.getClasses();
  +Path p = new Path(null);
  +p.addJavaRuntime();
  +ClassPathLoader cl = new ClassPathLoader(p.toString());
  +Hashtable map = cl.getClasses();
   assertTrue(map.size()  0);
   }
   
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/types Path.java

2003-03-11 Thread bodewig
bodewig 2003/03/11 02:57:43

  Modified:src/main/org/apache/tools/ant/types Path.java
  Log:
  Adapt to JDK 1.4.1 for Mac OS X.
  
  Note that there are more jars in that directory that I'm not sure
  about (whether we want to add them in addJavaRuntime, that is).
  
  Revision  ChangesPath
  1.47  +6 -1  ant/src/main/org/apache/tools/ant/types/Path.java
  
  Index: Path.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/types/Path.java,v
  retrieving revision 1.46
  retrieving revision 1.47
  diff -u -r1.46 -r1.47
  --- Path.java 7 Mar 2003 11:23:07 -   1.46
  +++ Path.java 11 Mar 2003 10:57:42 -  1.47
  @@ -621,12 +621,17 @@
+ File.separator + lib
+ File.separator + rt.jar));
   
  -// Sun's 1.4 has JCE and JSSE in separate jars.
  +// Sun's and Apple's 1.4 have JCE and JSSE in separate jars.
   String[] secJars = { jce, jsse };
   for (int i = 0; i  secJars.length; i++) {
   addExisting(new Path(null,
System.getProperty(java.home)
+ File.separator + lib
  + + File.separator + secJars[i] + 
.jar));
  +addExisting(new Path(null,
  + System.getProperty(java.home)
  + + File.separator + ..
  + + File.separator + Classes
+ File.separator + secJars[i] + 
.jar));
   }
   
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh SSHBase.java SSHUserInfo.java Scp.java

2003-03-11 Thread bodewig
bodewig 2003/03/11 05:00:31

  Modified:src/main/org/apache/tools/ant/taskdefs/optional/ssh Scp.java
  Added:   src/main/org/apache/tools/ant/taskdefs/optional/ssh
SSHBase.java SSHUserInfo.java
  Log:
  Add key based authentication to scp.
  
  Submitted by: Robert Anderson riznob at hotmail dot com
  
  Revision  ChangesPath
  1.4   +48 -140   
ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/Scp.java
  
  Index: Scp.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/Scp.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- Scp.java  10 Mar 2003 10:05:43 -  1.3
  +++ Scp.java  11 Mar 2003 13:00:31 -  1.4
  @@ -74,19 +74,11 @@
* @author [EMAIL PROTECTED]
* @since Ant 1.6
*/
  -public class Scp extends Task implements LogListener {
  +public class Scp extends SSHBase {
   
   private String fromUri;
   private String toUri;
  -private String knownHosts;
  -private boolean trust = false;
  -private int port = 22;
   private List fileSets = null;
  -private boolean failOnError = true;
  -
  -public void setFailonerror( boolean failure ) {
  -failOnError = failure;
  -}
   
   /**
* Sets the file to be transferred.  This can either be a remote
  @@ -114,35 +106,7 @@
   this.toUri = aToUri;
   }
   
  -/**
  - * Sets the path to the file that has the identities of
  - * all known hosts.  This is used by SSH protocol to validate
  - * the identity of the host.  The default is
  - * i${user.home}/.ssh/known_hosts/i.
  -
  - * @param knownHosts a path to the known hosts file.
  - */
  -public void setKnownhosts( String knownHosts ) {
  -this.knownHosts = knownHosts;
  -}
   
  -/**
  - * Setting this to true trusts hosts whose identity is unknown.
  - *
  - * @param yesOrNo if true trust the identity of unknown hosts.
  - */
  -public void setTrust( boolean yesOrNo ) {
  -this.trust = yesOrNo;
  -}
  -
  -/**
  - * Changes the port used to connect to the remote host.
  - *
  - * @param port port number of remote host.
  - */
  -public void setPort( int port ) {
  -this.port = port;
  -}
   
   /**
* Adds a FileSet tranfer to remote host.  NOTE: Either
  @@ -161,9 +125,6 @@
   super.init();
   this.toUri = null;
   this.fromUri = null;
  -this.knownHosts = System.getProperty(user.home) + 
/.ssh/known_hosts;
  -this.trust = false;
  -this.port = 22;
   this.fileSets = null;
   }
   
  @@ -174,12 +135,13 @@
   
   if ( fromUri == null  fileSets == null ) {
   throw new BuildException(Either the 'file' attribute or one  +
  -FileSet is required.);
  + FileSet is required.);
   }
   
   boolean isFromRemote = false;
  -if( fromUri != null )
  +if( fromUri != null ) {
   isFromRemote = isRemoteUri(fromUri);
  +}
   boolean isToRemote = isRemoteUri(toUri);
   try {
   if (isFromRemote  !isToRemote) {
  @@ -194,11 +156,11 @@
   // not implemented yet.
   } else {
   throw new BuildException('todir' and 'file' attributes  +
  -must have syntax like the following:  +
  -user:[EMAIL PROTECTED]:/path);
  + must have syntax like the 
following:  +
  + user:[EMAIL PROTECTED]:/path);
   }
   } catch (Exception e) {
  -if( failOnError ) {
  +if(getFailonerror()) {
   throw new BuildException(e);
   } else {
   log(Caught exception:  + e.getMessage(), Project.MSG_ERR);
  @@ -207,20 +169,17 @@
   }
   
   private void download( String fromSshUri, String toPath )
  -throws JSchException, IOException {
  -String[] fromValues = parseUri(fromSshUri);
  +throws JSchException, IOException {
  +String file = parseUri(fromSshUri);
   
   Session session = null;
   try {
  -session = openSession(fromValues[0],
  -fromValues[1],
  -fromValues[2],
  -port );
  +session = openSession();
   ScpFromMessage message = new ScpFromMessage( session,
  -fromValues[3],
  -new File( toPath ),
  -fromSshUri.endsWith(*) );
  -log(Receiving file:  + fromValues[3] );
  + file

cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh SSHExec.java SSHBase.java

2003-03-11 Thread bodewig
bodewig 2003/03/11 05:15:44

  Modified:src/main/org/apache/tools/ant/taskdefs defaults.properties
   src/main/org/apache/tools/ant/taskdefs/optional/ssh
SSHBase.java
  Added:   src/main/org/apache/tools/ant/taskdefs/optional/ssh
SSHExec.java
  Log:
  New task sshexec.
  
  Submitted by: Robert Anderson riznob at hotmail dot com
  
  Revision  ChangesPath
  1.141 +1 -0  
ant/src/main/org/apache/tools/ant/taskdefs/defaults.properties
  
  Index: defaults.properties
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/defaults.properties,v
  retrieving revision 1.140
  retrieving revision 1.141
  diff -u -r1.140 -r1.141
  --- defaults.properties   6 Mar 2003 12:42:44 -   1.140
  +++ defaults.properties   11 Mar 2003 13:15:43 -  1.141
  @@ -182,6 +182,7 @@
   chown=org.apache.tools.ant.taskdefs.optional.unix.Chown
   attrib=org.apache.tools.ant.taskdefs.optional.windows.Attrib
   scp=org.apache.tools.ant.taskdefs.optional.ssh.Scp
  +sshexec=org.apache.tools.ant.taskdefs.optional.ssh.SSHExec
   
   # deprecated ant tasks (kept for back compatibility)
   starteam=org.apache.tools.ant.taskdefs.optional.scm.AntStarTeamCheckOut
  
  
  
  1.2   +3 -0  
ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/SSHBase.java
  
  Index: SSHBase.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/SSHBase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- SSHBase.java  11 Mar 2003 13:00:31 -  1.1
  +++ SSHBase.java  11 Mar 2003 13:15:43 -  1.2
  @@ -102,6 +102,9 @@
   this.host = host;
   }
   
  +public String getHost() {
  +return host;
  +}
   
   public void setFailonerror( boolean failure ) {
   failOnError = failure;
  
  
  
  1.1  
ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/SSHExec.java
  
  Index: SSHExec.java
  ===
  /*
   * The Apache Software License, Version 1.1
   *
   * Copyright (c) 2003 The Apache Software Foundation.  All rights
   * reserved.
   *
   * Redistribution and use in source and binary forms, with or without
   * modification, are permitted provided that the following conditions
   * are met:
   *
   * 1. Redistributions of source code must retain the above copyright
   *notice, this list of conditions and the following disclaimer.
   *
   * 2. Redistributions in binary form must reproduce the above copyright
   *notice, this list of conditions and the following disclaimer in
   *the documentation and/or other materials provided with the
   *distribution.
   *
   * 3. The end-user documentation included with the redistribution, if
   *any, must include the following acknowlegement:
   *   This product includes software developed by the
   *Apache Software Foundation (http://www.apache.org/).
   *Alternately, this acknowlegement may appear in the software itself,
   *if and wherever such third-party acknowlegements normally appear.
   *
   * 4. The names Ant and Apache Software
   *Foundation must not be used to endorse or promote products derived
   *from this software without prior written permission. For written
   *permission, please contact [EMAIL PROTECTED]
   *
   * 5. Products derived from this software may not be called Apache
   *nor may Apache appear in their names without prior written
   *permission of the Apache Group.
   *
   * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
   * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
   * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
   * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
   * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
   * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
   * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
   * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
   * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
   * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
   * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
   * SUCH DAMAGE.
   * 
   *
   * This software consists of voluntary contributions made by many
   * individuals on behalf of the Apache Software Foundation.  For more
   * information on the Apache Software Foundation, please see
   * http://www.apache.org/.
   */
  
  package org.apache.tools.ant.taskdefs.optional.ssh;
  
  import org.apache.tools.ant.BuildException;
  import

cvs commit: ant/docs/manual/OptionalTasks scp.html

2003-03-11 Thread bodewig
bodewig 2003/03/11 05:56:58

  Modified:docs/manual/OptionalTasks scp.html
  Log:
  document new scp functionality
  
  Revision  ChangesPath
  1.3   +42 -2 ant/docs/manual/OptionalTasks/scp.html
  
  Index: scp.html
  ===
  RCS file: /home/cvs/ant/docs/manual/OptionalTasks/scp.html,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- scp.html  7 Mar 2003 14:53:36 -   1.2
  +++ scp.html  11 Mar 2003 13:56:58 -  1.3
  @@ -28,14 +28,18 @@
 tr
   td valign=topfile/td
   td valign=topThe file to copy.  This can be a local path or a
  -remote path of the form iuser:[EMAIL 
PROTECTED]:/directory/path./i/td
  +remote path of the form iuser[:[EMAIL PROTECTED]:/directory/path/i.
  +i:password/i can be ommitted if you use key based
  +authentication or specify the password attribute./td
   td valign=top align=centerYes, unless a nested
   codelt;filesetgt;/code element is used./td
 /tr
 tr
   td valign=toptodir/td
   td valign=topThe directory to copy to.  This can be a local path
  -or a remote path of the form iuser:[EMAIL 
PROTECTED]:/directory/path/i/td
  +or a remote path of the form iuser[:[EMAIL 
PROTECTED]:/directory/path/i.
  +i:password/i can be ommitted if you use key based
  +authentication or specify the password attribute./td
   td valian=top align=centerYes/td
 /tr
 tr
  @@ -63,6 +67,25 @@
/td
td valign=top align=centerNo; defaults to true./td
 /tr
  +  tr
  +td valign=toppassword/td
  + td valign=topThe password./td
  + td valign=top align=centerNot if you are using key based
  + authentication or the password has been given in the file or
  + todir attribute./td
  +  /tr
  +  tr
  +td valign=topkeyfile/td
  + td valign=topLocation of the file holding the private key./td
  + td valign=top align=centerYes, if you are using key based
  + authentication./td
  +  /tr
  +  tr
  +td valign=toppassphrase/td
  + td valign=topPassphrase for your private key./td
  + td valign=top align=centerYes, if you are using key based
  + authentication./td
  +  /tr
   /table
   h3Parameters specified as nested elements/h3
   
  @@ -76,6 +99,23 @@
   pre
 lt;scp file=quot;myfile.txtquot; todir=quot;user:[EMAIL 
PROTECTED]:/home/chuckquot;/gt;
   /pre
  +
  +pbCopy a single local file to a remote machine with separate
  +password attribute/b/p
  +pre
  +  lt;scp file=quot;myfile.txtquot; todir=quot;[EMAIL 
PROTECTED]:/home/chuckquot; password=quot;passwordquot;/gt;
  +/pre
  +
  +pbCopy a single local file to a remote machine using key base
  +authentication./b/p
  +pre
  +  lt;scp file=quot;myfile.txtquot;
  +   todir=quot;[EMAIL PROTECTED]:/home/chuckquot; 
  +   keyfile=quot;${user.home}/.ssh/id_dsaquot;
  +   passphrase=quot;my extremely secret passphrasequot;
  +  /gt;
  +/pre
  +
   pbCopy a single remote file to a local directory/b/p
   pre
 lt;scp file=quot;user:[EMAIL PROTECTED]:/home/chuck/myfile.txtquot; 
todir=quot;../some/other/dirquot;/gt;
  
  
  


cvs commit: ant/src/testcases/org/apache/tools/ant/taskdefs JarTest.java

2003-03-12 Thread bodewig
bodewig 2003/03/12 02:19:59

  Modified:src/etc/testcases/taskdefs jar.xml
   src/testcases/org/apache/tools/ant/taskdefs JarTest.java
  Log:
  currently failing testcase to demonstrate PR: 17780
  
  Revision  ChangesPath
  1.10  +11 -0 ant/src/etc/testcases/taskdefs/jar.xml
  
  Index: jar.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/taskdefs/jar.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- jar.xml   26 Feb 2003 09:57:01 -  1.9
  +++ jar.xml   12 Mar 2003 10:19:59 -  1.10
  @@ -189,4 +189,15 @@
   /jar
 /target
   
  +  !-- bug 17780 --
  +  target name=testUpdateIfOnlyManifestHasChanged
  +  depends=test4
  +jar destfile=${tmp.jar} update=true
  +  manifest
  +attribute name=Foo value=bar/
  +  /manifest
  +/jar
  +mkdir dir=${tmp.dir}/
  +unzip src=${tmp.jar} dest=${tmp.dir}/
  +  /target
   /project
  
  
  
  1.19  +9 -2  
ant/src/testcases/org/apache/tools/ant/taskdefs/JarTest.java
  
  Index: JarTest.java
  ===
  RCS file: 
/home/cvs/ant/src/testcases/org/apache/tools/ant/taskdefs/JarTest.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- JarTest.java  26 Feb 2003 09:57:01 -  1.18
  +++ JarTest.java  12 Mar 2003 10:19:59 -  1.19
  @@ -67,6 +67,7 @@
   public class JarTest extends BuildFileTest {
   
   private static String tempJar = tmp.jar;
  +private static String tempDir = jartmp/;
   private Reader r1, r2;
   
   public JarTest(String name) {
  @@ -170,9 +171,9 @@
   executeTarget(testManifestStaysIntact);
   
   r1 = new FileReader(getProject()
  -.resolveFile(jartmp/manifest));
  +.resolveFile(tempDir + manifest));
   r2 = new FileReader(getProject()
  -.resolveFile(jartmp/META-INF/MANIFEST.MF));
  +.resolveFile(tempDir + META-INF/MANIFEST.MF));
   Manifest mf1 = new Manifest(r1);
   Manifest mf2 = new Manifest(r2);
   assertEquals(mf1, mf2);
  @@ -218,5 +219,11 @@
   executeTarget(testCreateWithEmptyFilesetSetUp);
   executeTarget(testCreateWithEmptyFileset);
   executeTarget(testCreateWithEmptyFileset);
  +}
  +
  +public void testUpdateIfOnlyManifestHasChanged() {
  +executeTarget(testUpdateIfOnlyManifestHasChanged);
  +File jarXml = getProject().resolveFile(tempDir + jar.xml);
  +assertTrue(jarXml.exists());
   }
   }
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs Jar.java Zip.java

2003-03-12 Thread bodewig
bodewig 2003/03/12 03:23:28

  Modified:src/main/org/apache/tools/ant/taskdefs Jar.java Zip.java
  Log:
  Fix the bug.
  
  PR: 17780
  
  Revision  ChangesPath
  1.71  +5 -3  ant/src/main/org/apache/tools/ant/taskdefs/Jar.java
  
  Index: Jar.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Jar.java,v
  retrieving revision 1.70
  retrieving revision 1.71
  diff -u -r1.70 -r1.71
  --- Jar.java  17 Feb 2003 14:00:34 -  1.70
  +++ Jar.java  12 Mar 2003 11:23:27 -  1.71
  @@ -531,11 +531,12 @@
* out-of-date.  Subclasses overriding this method are supposed to
* set this value correctly in their call to
* super.getResourcesToAdd.
  - * @return an array of resources to add for each fileset passed in.
  + * @return an array of resources to add for each fileset passed in as 
well
  + * as a flag that indicates whether the archive is uptodate.
*
* @exception BuildException if it likes
*/
  -protected Resource[][] getResourcesToAdd(FileSet[] filesets,
  +protected ArchiveState getResourcesToAdd(FileSet[] filesets,
File zipFile,
boolean needsUpdate)
   throws BuildException {
  @@ -581,7 +582,8 @@
   
   ZipOutputStream zOut = null;
   try {
  -log(Building jar:  + getDestFile().getAbsolutePath());
  +log(Building MANIFEST-only jar:  
  ++ getDestFile().getAbsolutePath());
   zOut = new ZipOutputStream(new FileOutputStream(getDestFile()));
   
   zOut.setEncoding(getEncoding());
  
  
  
  1.101 +64 -11ant/src/main/org/apache/tools/ant/taskdefs/Zip.java
  
  Index: Zip.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Zip.java,v
  retrieving revision 1.100
  retrieving revision 1.101
  diff -u -r1.100 -r1.101
  --- Zip.java  7 Mar 2003 11:23:03 -   1.100
  +++ Zip.java  12 Mar 2003 11:23:27 -  1.101
  @@ -344,7 +344,11 @@
   // we don't need to update if the original file doesn't exist
   
   addingNewFiles = true;
  -doUpdate = doUpdate  zipFile.exists();
  +if (doUpdate  !zipFile.exists()) {
  +doUpdate = false;
  +log(ignoring update attribute as  + archiveType
  ++  doesn't exist., Project.MSG_DEBUG);
  +}
   
   // Add the files found in groupfileset to fileset
   for (int i = 0; i  groupfilesets.size(); i++) {
  @@ -381,14 +385,16 @@
   vfss.copyInto(fss);
   boolean success = false;
   try {
  -Resource[][] addThem = getResourcesToAdd(fss, zipFile, false);
  +// can also handle empty archives
  +ArchiveState state = getResourcesToAdd(fss, zipFile, false);
   
   // quick exit if the target is up to date
  -// can also handle empty archives
  -if (isEmpty(addThem)) {
  +if (!state.isOutOfDate()) {
   return;
   }
   
  +Resource[][] addThem = state.getResourcesToAdd();
  +
   if (doUpdate) {
   renamedFile =
   fileUtils.createTempFile(zip, .tmp,
  @@ -687,17 +693,38 @@
* out-of-date.  Subclasses overriding this method are supposed to
* set this value correctly in their call to
* super.getResourcesToAdd.
  - * @return an array of resources to add for each fileset passed in.
  + * @return an array of resources to add for each fileset passed in as 
well
  + * as a flag that indicates whether the archive is uptodate.
*
* @exception BuildException if it likes
*/
  -protected Resource[][] getResourcesToAdd(FileSet[] filesets,
  +protected ArchiveState getResourcesToAdd(FileSet[] filesets,
File zipFile,
boolean needsUpdate)
   throws BuildException {
   
   Resource[][] initialResources = grabResources(filesets);
   if (isEmpty(initialResources)) {
  +if (needsUpdate  doUpdate) {
  +/*
  + * This is a rather hairy case.
  + *
  + * One of our subclasses knows that we need to update the
  + * archive, but at the same time, there are no resources
  + * known to us that would need to be added.  Only the
  + * subclass seems to know what's going on.
  + *
  + * This happens if jar detects that the manifest has 
changed,
  + * for example.  The manifest is not part of any

cvs commit: ant/src/testcases/org/apache/tools/ant/taskdefs JarTest.java

2003-03-12 Thread bodewig
bodewig 2003/03/12 03:29:10

  Modified:src/etc/testcases/taskdefs Tag: ANT_15_BRANCH jar.xml
   src/main/org/apache/tools/ant/taskdefs Tag: ANT_15_BRANCH
Jar.java Zip.java
   src/testcases/org/apache/tools/ant/taskdefs Tag:
ANT_15_BRANCH JarTest.java
  Log:
  Merge tests and fix for bug 17780 from HEAD
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.4.2.4   +11 -0 ant/src/etc/testcases/taskdefs/jar.xml
  
  Index: jar.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/taskdefs/jar.xml,v
  retrieving revision 1.4.2.3
  retrieving revision 1.4.2.4
  diff -u -r1.4.2.3 -r1.4.2.4
  --- jar.xml   26 Feb 2003 10:07:00 -  1.4.2.3
  +++ jar.xml   12 Mar 2003 11:29:09 -  1.4.2.4
  @@ -189,4 +189,15 @@
   /jar
 /target
   
  +  !-- bug 17780 --
  +  target name=testUpdateIfOnlyManifestHasChanged
  +  depends=test4
  +jar destfile=${tmp.jar} update=true
  +  manifest
  +attribute name=Foo value=bar/
  +  /manifest
  +/jar
  +mkdir dir=${tmp.dir}/
  +unzip src=${tmp.jar} dest=${tmp.dir}/
  +  /target
   /project
  
  
  
  No   revision
  
  
  No   revision
  
  
  1.51.2.17 +5 -3  ant/src/main/org/apache/tools/ant/taskdefs/Jar.java
  
  Index: Jar.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Jar.java,v
  retrieving revision 1.51.2.16
  retrieving revision 1.51.2.17
  diff -u -r1.51.2.16 -r1.51.2.17
  --- Jar.java  19 Feb 2003 08:13:59 -  1.51.2.16
  +++ Jar.java  12 Mar 2003 11:29:10 -  1.51.2.17
  @@ -535,11 +535,12 @@
* out-of-date.  Subclasses overriding this method are supposed to
* set this value correctly in their call to
* super.getResourcesToAdd.
  - * @return an array of resources to add for each fileset passed in.
  + * @return an array of resources to add for each fileset passed in as 
well
  + * as a flag that indicates whether the archive is uptodate.
*
* @exception BuildException if it likes
*/
  -protected Resource[][] getResourcesToAdd(FileSet[] filesets,
  +protected ArchiveState getResourcesToAdd(FileSet[] filesets,
File zipFile,
boolean needsUpdate)
   throws BuildException {
  @@ -585,7 +586,8 @@
   
   ZipOutputStream zOut = null;
   try {
  -log(Building jar:  + getDestFile().getAbsolutePath());
  +log(Building MANIFEST-only jar:  
  ++ getDestFile().getAbsolutePath());
   zOut = new ZipOutputStream(new FileOutputStream(getDestFile()));
   
   zOut.setEncoding(getEncoding());
  
  
  
  1.78.2.13 +64 -11ant/src/main/org/apache/tools/ant/taskdefs/Zip.java
  
  Index: Zip.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Zip.java,v
  retrieving revision 1.78.2.12
  retrieving revision 1.78.2.13
  diff -u -r1.78.2.12 -r1.78.2.13
  --- Zip.java  7 Mar 2003 12:38:39 -   1.78.2.12
  +++ Zip.java  12 Mar 2003 11:29:10 -  1.78.2.13
  @@ -327,7 +327,11 @@
   // we don't need to update if the original file doesn't exist
   
   addingNewFiles = true;
  -doUpdate = doUpdate  zipFile.exists();
  +if (doUpdate  !zipFile.exists()) {
  +doUpdate = false;
  +log(ignoring update attribute as  + archiveType
  ++  doesn't exist., Project.MSG_DEBUG);
  +}
   
   // Add the files found in groupfileset to fileset
   for (int i = 0; i  groupfilesets.size(); i++) {
  @@ -364,14 +368,16 @@
   vfss.copyInto(fss);
   boolean success = false;
   try {
  -Resource[][] addThem = getResourcesToAdd(fss, zipFile, false);
  +// can also handle empty archives
  +ArchiveState state = getResourcesToAdd(fss, zipFile, false);
   
   // quick exit if the target is up to date
  -// can also handle empty archives
  -if (isEmpty(addThem)) {
  +if (!state.isOutOfDate()) {
   return;
   }
   
  +Resource[][] addThem = state.getResourcesToAdd();
  +
   if (doUpdate) {
   renamedFile =
   fileUtils.createTempFile(zip, .tmp,
  @@ -666,17 +672,38 @@
* out-of-date.  Subclasses overriding this method are supposed to
* set this value correctly in their call to
* super.getResourcesToAdd.
  - * @return an array of resources to add for each

cvs commit: ant WHATSNEW

2003-03-12 Thread bodewig
bodewig 2003/03/12 03:41:06

  Modified:.Tag: ANT_15_BRANCH WHATSNEW
  Log:
  keep track of changes
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.263.2.125 +25 -0 ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.263.2.124
  retrieving revision 1.263.2.125
  diff -u -r1.263.2.124 -r1.263.2.125
  --- WHATSNEW  28 Feb 2003 15:19:58 -  1.263.2.124
  +++ WHATSNEW  12 Mar 2003 11:41:05 -  1.263.2.125
  @@ -1,3 +1,28 @@
  +Changes from Ant 1.5.2 to Ant 1.5.3
  +===
  +
  +Changes that could break older environments:
  +
  +
  +* The zip task and friends have again changed a method signature
  +  (sorry, was necessary to fix bug 17780).  The return type of
  +  getResourcesToAdd has changed.
  +
  +Fixed bugs:
  +---
  +
  +* zipfileset's filemode would get ignored and the dirmode was used
  +  for the included files as well.  As a side effect, WinZIP was unable
  +  to extract or display the files, so they seemed to be missing from
  +  the archive.  Bugzilla Report 17648.
  +
  +* ftp could use the wrong path separator when trying to change the
  +  remote working directory.  Bugzilla Report 17735.
  +
  +* jar update=true would loose all original files if you didn't
  +  specify any nested (zip)filesets and the manifest had changed.
  +  Bugzilla Report 17780.
  +
   Changes from Ant 1.5.1 to Ant 1.5.2
   ===
   
  
  
  


cvs commit: ant WHATSNEW

2003-03-12 Thread bodewig
bodewig 2003/03/12 03:41:36

  Modified:.WHATSNEW
  Log:
  keep track of changes
  
  Revision  ChangesPath
  1.362 +25 -0 ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.361
  retrieving revision 1.362
  diff -u -r1.361 -r1.362
  --- WHATSNEW  6 Mar 2003 12:42:43 -   1.361
  +++ WHATSNEW  12 Mar 2003 11:41:36 -  1.362
  @@ -161,6 +161,31 @@
 jsch, a BSD licensed SSH library that can be found at 
 http://www.jcraft.com/jsch/index.html
   
  +Changes from Ant 1.5.2 to Ant 1.5.3
  +===
  +
  +Changes that could break older environments:
  +
  +
  +* The zip task and friends have again changed a method signature
  +  (sorry, was necessary to fix bug 17780).  The return type of
  +  getResourcesToAdd has changed.
  +
  +Fixed bugs:
  +---
  +
  +* zipfileset's filemode would get ignored and the dirmode was used
  +  for the included files as well.  As a side effect, WinZIP was unable
  +  to extract or display the files, so they seemed to be missing from
  +  the archive.  Bugzilla Report 17648.
  +
  +* ftp could use the wrong path separator when trying to change the
  +  remote working directory.  Bugzilla Report 17735.
  +
  +* jar update=true would loose all original files if you didn't
  +  specify any nested (zip)filesets and the manifest had changed.
  +  Bugzilla Report 17780.
  +
   Changes from Ant 1.5.1 to Ant 1.5.2
   =
   
  
  
  


cvs commit: ant/xdocs bindownload.xml

2003-03-14 Thread bodewig
bodewig 2003/03/14 01:23:59

  Modified:docs bindownload.html
   xdocsbindownload.xml
  Log:
  Henri doesn't have the time to upload every new Ant RPM anymore,
  better stop providing them from our site, then.
  
  Revision  ChangesPath
  1.19  +2 -1  ant/docs/bindownload.html
  
  Index: bindownload.html
  ===
  RCS file: /home/cvs/ant/docs/bindownload.html,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- bindownload.html  3 Mar 2003 15:24:12 -   1.18
  +++ bindownload.html  14 Mar 2003 09:23:58 -  1.19
  @@ -218,7 +218,8 @@
   than 100 characters and have been created using GNU tar extensions.
   Thus they must be untarred with a GNU compatible version of
   codetar/code./p
  -pIn addition we provide RPMs created and 
maintained by the a href=http://www.jpackage.org;JPackage team/a, see the 
a href=[preferred]/ant/binaries/rpms/distribution directory/a./p
  +pIn addition the a 
href=http://www.jpackage.org;JPackage
  +project/a provides RPMs at their own distribution site./p
   pIf you do not see the file you need in 
the links below, please see
   the a href=http://www.apache.org/dist/ant/;master distribution
   directory/a or, preferably, its a href=[preferred]/ant/mirror/a./p
  
  
  
  1.11  +2 -3  ant/xdocs/bindownload.xml
  
  Index: bindownload.xml
  ===
  RCS file: /home/cvs/ant/xdocs/bindownload.xml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- bindownload.xml   3 Mar 2003 15:24:14 -   1.10
  +++ bindownload.xml   14 Mar 2003 09:23:59 -  1.11
  @@ -23,9 +23,8 @@
   Thus they must be untarred with a GNU compatible version of
   codetar/code./p
   
  -pIn addition we provide RPMs created and maintained by the a
  -href=http://www.jpackage.org;JPackage team/a, see the a
  -href=[preferred]/ant/binaries/rpms/distribution directory/a./p
  +pIn addition the a href=http://www.jpackage.org;JPackage
  +project/a provides RPMs at their own distribution site./p
   
   pIf you do not see the file you need in the links below, please see
   the a href=http://www.apache.org/dist/ant/;master distribution
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs SQLExec.java

2003-03-14 Thread bodewig
bodewig 2003/03/14 01:24:41

  Modified:src/main/org/apache/tools/ant/taskdefs SQLExec.java
  Log:
  Remove reference to Jakarta
  
  Revision  ChangesPath
  1.51  +1 -1  ant/src/main/org/apache/tools/ant/taskdefs/SQLExec.java
  
  Index: SQLExec.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/SQLExec.java,v
  retrieving revision 1.50
  retrieving revision 1.51
  diff -u -r1.50 -r1.51
  --- SQLExec.java  13 Mar 2003 21:41:11 -  1.50
  +++ SQLExec.java  14 Mar 2003 09:24:41 -  1.51
  @@ -23,7 +23,7 @@
*Alternately, this acknowlegement may appear in the software itself,
*if and wherever such third-party acknowlegements normally appear.
*
  - * 4. The names The Jakarta Project, Ant, and Apache Software
  + * 4. The names Ant and Apache Software
*Foundation must not be used to endorse or promote products derived
*from this software without prior written permission. For written
*permission, please contact [EMAIL PROTECTED]
  
  
  


cvs commit: ant/src/testcases/org/apache/tools/ant/filters EscapeUnicodeTest.java

2003-03-14 Thread bodewig
bodewig 2003/03/14 05:45:17

  Modified:docs/manual/CoreTypes filterchain.html
   src/etc/testcases/filters build.xml
   src/main/org/apache/tools/ant/types FilterChain.java
  Added:   src/etc/testcases/filters/expected escapeunicode.test
   src/etc/testcases/filters/input escapeunicode.test
   src/main/org/apache/tools/ant/filters EscapeUnicode.java
   src/testcases/org/apache/tools/ant/filters
EscapeUnicodeTest.java
  Log:
  New filter escapeunicode that translates non-ASCII characters to
  \u1234 escapes.
  
  addresses PR: 17506
  
  Revision  ChangesPath
  1.5   +29 -1 ant/docs/manual/CoreTypes/filterchain.html
  
  Index: filterchain.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTypes/filterchain.html,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- filterchain.html  3 Sep 2002 15:24:08 -   1.4
  +++ filterchain.html  14 Mar 2003 13:45:16 -  1.5
  @@ -89,6 +89,7 @@
   nested elements.BR
   a href=#filterreaderFilterReader/aBR
   a href=#classconstantsClassConstants/aBR
  +a href=#escapeunicodeEscapeUnicode/aBR
   a href=#expandpropertiesExpandProperties/aBR
   a href=#headfilterHeadFilter/aBR
   a href=#linecontainsLineContains/aBR
  @@ -162,6 +163,33 @@
   lt;/loadpropertiesgt;
   /PRE/BLOCKQUOTE
   
  +H3a name=escapeunicodeEscapeUnicode/a/H3
  +P
  +This filter converts its input by changing all non US-ASCII characters
  +into their equivalent unicode escape backslash u plus 4 digits./p
  +
  +Pemsince Ant 1.6/em/p
  +
  +H4Example:/H4
  +
  +This loads the basic constants defined in a Java class as Ant properties.
  +BLOCKQUOTEPRE
  +lt;loadproperties srcfile=quot;non_ascii_property.propertiesquot;gt;
  +  lt;filterchaingt;
  +lt;filterreader 
classname=quot;org.apache.tools.ant.filters.EscapeUnicodequot;/gt;
  +  lt;/filterchaingt;
  +lt;/loadpropertiesgt;
  +/PRE/BLOCKQUOTE
  +
  +Convenience method:
  +BLOCKQUOTEPRE
  +lt;loadproperties srcfile=quot;non_ascii_property.propertiesquot;gt;
  +  lt;filterchaingt;
  +lt;escapeunicode/gt;
  +  lt;/filterchaingt;
  +lt;/loadpropertiesgt;
  +/PRE/BLOCKQUOTE
  +
   H3a name=expandpropertiesExpandProperties/a/H3
   P
   If the data contains data that represents Ant
  @@ -629,5 +657,5 @@
   
   HR
   
  -P align=centerCopyright copy; 2002 Apache Software Foundation. All rights
  +P align=centerCopyright copy; 2002-2003 Apache Software Foundation. All 
rights
   Reserved./P/BODY/HTML
  
  
  
  1.2   +21 -2 ant/src/etc/testcases/filters/build.xml
  
  Index: build.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/filters/build.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- build.xml 30 Sep 2002 12:08:20 -  1.1
  +++ build.xml 14 Mar 2003 13:45:16 -  1.2
  @@ -6,18 +6,37 @@
 /target
   
 target name=cleanup
  -delete dir=result /
  +delete dir=result/
 /target
   
 target name=testLineContains depends=init
   copy todir=result
  -  fileset dir=input/
  +  fileset dir=input
  +include name=linecontains.test/
  +  /fileset
 filterchain
   filterreader classname=org.apache.tools.ant.filters.LineContains
 param type=contains value=beta/
   /filterreader
 /filterchain
   /copy
  +!--fixcrlf srcdir=result eol=lf
  +  include name=linecontains.test/
  +/fixcrlf--
  +  /target
  +
  +  target name=testEscapeUnicode depends=init
  +copy todir=result encoding=UTF-8
  +  fileset dir=input
  +include name=escapeunicode.test/
  +  /fileset
  +  filterchain
  +escapeunicode/
  +  /filterchain
  +/copy
  +fixcrlf srcdir=result eol=crlf
  +  include name=escapeunicode.test/
  +/fixcrlf
 /target
   
   /project
  
  
  
  1.1  ant/src/etc/testcases/filters/expected/escapeunicode.test
  
  Index: escapeunicode.test
  ===
  #hebrew shalom olam (hello world)
  text.hebrew=\u05e9\u05dc\u05d5\u05dd \u05e2\u05d5\u05dc\u05dd
  #goethe gingko biloba
  text.german.1=Sp\u00fcrst du nicht an meinen Liedern,
  text.german.2=Da\u00df ich eins und doppelt bin ?
  # Francois Villon Ballade des Pendus
  text.french=Fr\u00e8res humains qui apr\u00e8s nous vivez
  # Usual IT example
  text.basic.latin=Hello World 
  
  
  
  1.1  ant/src/etc/testcases/filters/input/escapeunicode.test
  
  Index: escapeunicode.test
  ===
  #hebrew shalom olam (hello world)
  text.hebrew=שלום עולם
  #goethe gingko biloba
  text.german.1=Spürst du nicht an meinen Liedern,
  text.german.2=Daß ich eins und doppelt bin ?
  # Francois

cvs commit: ant/src/main/org/apache/tools/ant/taskdefs Zip.java

2003-03-18 Thread bodewig
bodewig 2003/03/18 05:15:48

  Modified:src/main/org/apache/tools/ant/taskdefs Zip.java
  Log:
  JDK 1.1
  
  Revision  ChangesPath
  1.102 +2 -2  ant/src/main/org/apache/tools/ant/taskdefs/Zip.java
  
  Index: Zip.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Zip.java,v
  retrieving revision 1.101
  retrieving revision 1.102
  diff -u -r1.101 -r1.102
  --- Zip.java  12 Mar 2003 11:23:27 -  1.101
  +++ Zip.java  18 Mar 2003 13:15:48 -  1.102
  @@ -844,11 +844,11 @@
   Vector resources = new Vector();
   String[] directories = rs.getIncludedDirectories();
   for (int j = 0; j  directories.length; j++) {
  -resources.add(rs.getResource(directories[j]));
  +resources.addElement(rs.getResource(directories[j]));
   }
   String[] files = rs.getIncludedFiles();
   for (int j = 0; j  files.length; j++) {
  -resources.add(rs.getResource(files[j]));
  +resources.addElement(rs.getResource(files[j]));
   }
   
   result[i] = new Resource[resources.size()];
  
  
  


cvs commit: ant/xdocs external.xml projects.xml

2003-03-18 Thread bodewig
bodewig 2003/03/18 08:11:37

  Modified:docs external.html projects.html
   xdocsexternal.xml projects.xml
  Log:
  Pointers Submitted by:Jan.Materne Jan dot Materne at rzf dot fin 
dash nrw dot de
  Markus Gebhard markus at jave dot de
  Steve Neal S dot Neal at Smartkey dot co dot uk
  
  Revision  ChangesPath
  1.96  +105 -1ant/docs/external.html
  
  Index: external.html
  ===
  RCS file: /home/cvs/ant/docs/external.html,v
  retrieving revision 1.95
  retrieving revision 1.96
  diff -u -r1.95 -r1.96
  --- external.html 14 Mar 2003 12:03:51 -  1.95
  +++ external.html 18 Mar 2003 16:11:36 -  1.96
  @@ -1102,7 +1102,7 @@
 /font
   /td/tr
 /table
  -pThere are three different sets of tasks to help 
build a href=http://java.sun.com/j2me/;Java 2 Platform, Micro
  +pThere are four different sets of tasks to help 
build a href=http://java.sun.com/j2me/;Java 2 Platform, Micro
   Edition/a (J2ME) applications./p
   pThis set supports CLDC and the K Virtual 
Machine (KVM):/p
 table class=ForrestTable 
cellspacing=1 cellpadding=4
  @@ -1239,6 +1239,56 @@
 /td
 /tr
   /table
  +pAntic is a freely available task for 
packaging J2ME
  + applications. It produces both the Jar and Jad files in a
  + single step. This allows *all* entries to be correclty set in
  + the jad file, including the size of the jar file that is
  + produced. This task has been used and tested extensively with
  + Sun's Wireless Toolkit and also the Nokia SDK and
  + emulators./p
  +  table class=ForrestTable 
cellspacing=1 cellpadding=4
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Compatibility:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Ant 1.5
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  URL:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a 
href=http://www.smartkey.co.uk/antic.html;www.smartkey.co.uk/a
  +
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Contact:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a href=mailto:[EMAIL PROTECTED]smartkey.co.uk/a
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  License:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  GNU General Public License
  +  /td
  +  /tr
  +/table
   br/
 a name=Jacson/a
 table border=0 cellspacing=0 cellpadding=2 width=100%
  @@ -1422,6 +1472,60 @@
 td colspan=1 rowspan=1
 valign=top align=left
 BSD-like License
  +  /td
  +  /tr
  +/table
  +br/
  +  a name=Java2Html/a
  +  table border=0 cellspacing=0 cellpadding=2 width=100%
  +trtd bgcolor=#4C6C8F
  +  font color=#ff face=arial,helvetica,sanserif
  +strongJava2Html/strong
  +  /font
  +/td/tr
  +  /table
  +pUses the Java2Html library for converting java 
source files
  +or snipplets to syntax highlighted html, rtf, tex and
  +others./p
  +  table class=ForrestTable 
cellspacing=1 cellpadding=4
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Compatibility:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Ant 1.5 and later
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  URL:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a href=http://www.java2html.de;http://www.java2html.de/a
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Contact:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a href=mailto:[EMAIL PROTECTED][EMAIL

cvs commit: ant/xdocs external.xml

2003-03-18 Thread bodewig
bodewig 2003/03/18 08:15:38

  Modified:docs external.html
   xdocsexternal.xml
  Log:
  untabify
  
  Revision  ChangesPath
  1.97  +8 -8  ant/docs/external.html
  
  Index: external.html
  ===
  RCS file: /home/cvs/ant/docs/external.html,v
  retrieving revision 1.96
  retrieving revision 1.97
  diff -u -r1.96 -r1.97
  --- external.html 18 Mar 2003 16:11:36 -  1.96
  +++ external.html 18 Mar 2003 16:15:37 -  1.97
  @@ -1240,12 +1240,12 @@
 /tr
   /table
   pAntic is a freely available task for 
packaging J2ME
  - applications. It produces both the Jar and Jad files in a
  - single step. This allows *all* entries to be correclty set in
  - the jad file, including the size of the jar file that is
  - produced. This task has been used and tested extensively with
  - Sun's Wireless Toolkit and also the Nokia SDK and
  - emulators./p
  +applications. It produces both the Jar and Jad files in a
  +single step. This allows *all* entries to be correclty set in
  +the jad file, including the size of the jar file that is
  +produced. This task has been used and tested extensively with
  +Sun's Wireless Toolkit and also the Nokia SDK and
  +emulators./p
 table class=ForrestTable 
cellspacing=1 cellpadding=4
 tr
 th colspan=1 rowspan=1
  @@ -1299,8 +1299,8 @@
   /td/tr
 /table
   pJacson is a configurable and plugable tool (much 
like Ant
  - itself) to create filters for text (line based) files without
  - programming./p
  +itself) to create filters for text (line based) files without
  +programming./p
 table class=ForrestTable 
cellspacing=1 cellpadding=4
 tr
 th colspan=1 rowspan=1
  
  
  
  1.74  +12 -12ant/xdocs/external.xml
  
  Index: external.xml
  ===
  RCS file: /home/cvs/ant/xdocs/external.xml,v
  retrieving revision 1.73
  retrieving revision 1.74
  diff -u -r1.73 -r1.74
  --- external.xml  18 Mar 2003 16:11:37 -  1.73
  +++ external.xml  18 Mar 2003 16:15:38 -  1.74
  @@ -525,15 +525,15 @@
 /tr
   /table
   
  - pAntic is a freely available task for packaging J2ME
  - applications. It produces both the Jar and Jad files in a
  - single step. This allows *all* entries to be correclty set in
  - the jad file, including the size of the jar file that is
  - produced. This task has been used and tested extensively with
  - Sun's Wireless Toolkit and also the Nokia SDK and
  - emulators./p
  +pAntic is a freely available task for packaging J2ME
  +applications. It produces both the Jar and Jad files in a
  +single step. This allows *all* entries to be correclty set in
  +the jad file, including the size of the jar file that is
  +produced. This task has been used and tested extensively with
  +Sun's Wireless Toolkit and also the Nokia SDK and
  +emulators./p
   
  - table
  +table
 tr
   thCompatibility:/th
   tdAnt 1.5/td
  @@ -551,15 +551,15 @@
   thLicense:/th
   tdGNU General Public License/td
 /tr
  - /table
  +/table
   
 /subsection
   
 subsection name=Jacson
   
  - pJacson is a configurable and plugable tool (much like Ant
  - itself) to create filters for text (line based) files without
  - programming./p
  +pJacson is a configurable and plugable tool (much like Ant
  +itself) to create filters for text (line based) files without
  +programming./p
   
   table
 tr
  
  
  


cvs commit: ant/xdocs external.xml

2003-03-18 Thread bodewig
bodewig 2003/03/18 08:34:55

  Modified:docs external.html
   xdocsexternal.xml
  Log:
  Greebo has moved
  
  Revision  ChangesPath
  1.98  +2 -2  ant/docs/external.html
  
  Index: external.html
  ===
  RCS file: /home/cvs/ant/docs/external.html,v
  retrieving revision 1.97
  retrieving revision 1.98
  diff -u -r1.97 -r1.98
  --- external.html 18 Mar 2003 16:15:37 -  1.97
  +++ external.html 18 Mar 2003 16:34:55 -  1.98
  @@ -909,7 +909,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://www.discore.com/oz/new/index.htm;http://www.discore.com/oz/new/index.htm/a
  +  a 
href=http://greebo.sourceforge.net/;http://greebo.sourceforge.net//a
 /td
 /tr
 tr
  @@ -919,7 +919,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a href=mailto:[EMAIL PROTECTED]Ozben Evren/a
  +  a href=http://sourceforge.net/mail/?group_id=73733;project 
mailing lists/a
 /td
 /tr
 tr
  
  
  
  1.75  +2 -2  ant/xdocs/external.xml
  
  Index: external.xml
  ===
  RCS file: /home/cvs/ant/xdocs/external.xml,v
  retrieving revision 1.74
  retrieving revision 1.75
  diff -u -r1.74 -r1.75
  --- external.xml  18 Mar 2003 16:15:38 -  1.74
  +++ external.xml  18 Mar 2003 16:34:55 -  1.75
  @@ -362,11 +362,11 @@
 /tr
 tr
   thURL:/th
  -tda 
href=http://www.discore.com/oz/new/index.htm;http://www.discore.com/oz/new/index.htm/a/td
  +tda 
href=http://greebo.sourceforge.net/;http://greebo.sourceforge.net//a/td
 /tr
 tr
   thContact:/th
  -tda href=mailto:[EMAIL PROTECTED]Ozben Evren/a/td
  +tda 
href=http://sourceforge.net/mail/?group_id=73733;project mailing 
lists/a/td
 /tr
 tr
   thLicense:/th
  
  
  


cvs commit: ant/docs/manual/CoreTasks move.html

2003-03-19 Thread bodewig
bodewig 2003/03/19 00:33:10

  Modified:docs/manual/CoreTasks Tag: ANT_15_BRANCH move.html
  Log:
  Document some inherited attributes.
  
  PR: 17952
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.6.2.7   +21 -1 ant/docs/manual/CoreTasks/move.html
  
  Index: move.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/move.html,v
  retrieving revision 1.6.2.6
  retrieving revision 1.6.2.7
  diff -u -r1.6.2.6 -r1.6.2.7
  --- move.html 4 Sep 2002 11:21:12 -   1.6.2.6
  +++ move.html 19 Mar 2003 08:33:10 -  1.6.2.7
  @@ -30,6 +30,13 @@
at least one nested fileset element/td
 /tr
 tr
  +td valign=toppreservelastmodified/td
  +td valign=topGive the moved files the same last modified
  +  time as the original source files.
  +  (emNote/em: Ignored on Java 1.1)/td
  +td valign=top align=centerNo; defaults to false./td
  +  /tr
  +  tr
   td valign=toptofile/td
   td valign=topthe file to move to/td
   td valign=top align=center rowspan=2With the varfile/var 
attribute,
  @@ -69,6 +76,19 @@
   Defaults to quot;yesquot;./td
 td valign=top align=centerNo/td
 /tr
  +  tr
  +td valign=topfailonerror/td
  + td valign=topLog a warning message, but do not stop the build,
  +   when the file to move does not exist.
  +   Only meaningful when moving a single file.
  + /td
  + td valign=top align=centerNo; defaults to true./td
  +  /tr
  +  tr
  +td valign=topverbose/td
  + td valign=topLog the files that are being moved./td
  + td valign=top align=centerNo; defaults to false./td
  +  /tr
   /table
   h3Parameters specified as nested elements/h3
   h4mapper/h4
  @@ -121,7 +141,7 @@
 lt;/movegt;
   /pre
   hr
  -p align=centerCopyright copy; 2000-2002 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2000-2003 Apache Software Foundation. All 
rights
   Reserved./p
   
   /body
  
  
  


cvs commit: ant/docs/manual/OptionalTasks replaceregexp.html

2003-03-19 Thread bodewig
bodewig 2003/03/19 00:41:29

  Modified:docs/manual/OptionalTasks Tag: ANT_15_BRANCH
replaceregexp.html
  Log:
  Add another example to replaceregexp's docs.
  
  PR: 17660
  Submitted by: Jan Matèrne jan at materne dot de
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.8.2.4   +21 -1 ant/docs/manual/OptionalTasks/replaceregexp.html
  
  Index: replaceregexp.html
  ===
  RCS file: /home/cvs/ant/docs/manual/OptionalTasks/replaceregexp.html,v
  retrieving revision 1.8.2.3
  retrieving revision 1.8.2.4
  diff -u -r1.8.2.3 -r1.8.2.4
  --- replaceregexp.html4 Sep 2002 11:21:14 -   1.8.2.3
  +++ replaceregexp.html19 Mar 2003 08:41:29 -  1.8.2.4
  @@ -123,8 +123,28 @@
with quot;NewPropertyquot; in a properties file, preserving the existing
   value, in all files ending in code.properties/code in the current 
directory/p
   
  +blockquote
  +prelt;replaceregexp match=\s+ replace=  flags=g byline=truegt;
  +lt;fileset dir=${html.dir} includes=**/*.html /gt;
  +lt;/replaceregexpgt;
  +/pre/blockquote
  +preplaces all whitespaces (blanks, tabs, etc) by one blank remaining the
  +line separator. So with input
  +
  +blockquote
  +pre
  +lt;htmllt;bodygt;
  +lt;lt;TABgt;gt;lt;h1gt;T E S T   lt;/h1gt;  lt;lt;TABgt;gt;  
  
  +lt;lt;TABgt;gt; lt;/bodygt;lt;/htmlgt;
  +/pre/blockquote
  +would converted to
  +pre
  +lt;htmlgt; lt;bodygt;
  + lt;h1gt; T E S T lt;/h1gt; lt;/bodygt;lt;/htmlgt;
  +/pre
  +
   hr
  -p align=centerCopyright copy; 2001-2002 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2001-2003 Apache Software Foundation. All 
rights
   Reserved./p
   
   /body
  
  
  


cvs commit: ant/docs/manual/OptionalTasks replaceregexp.html

2003-03-19 Thread bodewig
bodewig 2003/03/19 00:42:14

  Modified:docs/manual/OptionalTasks replaceregexp.html
  Log:
  Merge fix for bug 17660 from 1.5 branch
  
  Revision  ChangesPath
  1.14  +20 -0 ant/docs/manual/OptionalTasks/replaceregexp.html
  
  Index: replaceregexp.html
  ===
  RCS file: /home/cvs/ant/docs/manual/OptionalTasks/replaceregexp.html,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- replaceregexp.html31 Jan 2003 12:15:51 -  1.13
  +++ replaceregexp.html19 Mar 2003 08:42:14 -  1.14
  @@ -128,6 +128,26 @@
with quot;NewPropertyquot; in a properties file, preserving the existing
   value, in all files ending in code.properties/code in the current 
directory/p
   
  +blockquote
  +prelt;replaceregexp match=\s+ replace=  flags=g byline=truegt;
  +lt;fileset dir=${html.dir} includes=**/*.html /gt;
  +lt;/replaceregexpgt;
  +/pre/blockquote
  +preplaces all whitespaces (blanks, tabs, etc) by one blank remaining the
  +line separator. So with input
  +
  +blockquote
  +pre
  +lt;htmllt;bodygt;
  +lt;lt;TABgt;gt;lt;h1gt;T E S T   lt;/h1gt;  lt;lt;TABgt;gt;  
  
  +lt;lt;TABgt;gt; lt;/bodygt;lt;/htmlgt;
  +/pre/blockquote
  +would converted to
  +pre
  +lt;htmlgt; lt;bodygt;
  + lt;h1gt; T E S T lt;/h1gt; lt;/bodygt;lt;/htmlgt;
  +/pre
  +
   hr
   p align=centerCopyright copy; 2001-2003 Apache Software Foundation. All 
rights
   Reserved./p
  
  
  


cvs commit: ant/docs/manual/CoreTasks loadproperties.html

2003-03-19 Thread bodewig
bodewig 2003/03/19 00:53:08

  Modified:docs/manual/CoreTasks Tag: ANT_15_BRANCH loadproperties.html
  Log:
  Point to prefixlines filter.
  
  PR: 17293
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.1.2.3   +7 -3  ant/docs/manual/CoreTasks/loadproperties.html
  
  Index: loadproperties.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/loadproperties.html,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -r1.1.2.2 -r1.1.2.3
  --- loadproperties.html   23 Sep 2002 11:08:43 -  1.1.2.2
  +++ loadproperties.html   19 Mar 2003 08:53:08 -  1.1.2.3
  @@ -13,9 +13,13 @@
   to lt;property file=quot;...quot;/gt; except that it
   supports nested lt;filterchaingt; elements and it cannot be
   specified outside a target.
  -
   /p
   
  +pIf you want to simulate a href=property.htmlproperty/a's
  +prefix attribute, please use a
  +href=../CoreTypes/filterchain.html#prefixlinesprefixlines/a
  +filter./p
  +
   h3Parameters/h3
   table border=1 cellpadding=2 cellspacing=0
 tr
  @@ -41,7 +45,7 @@
   prelt;loadproperties srcFile=file.propertiesgt;
 lt;filterchaingt;
   lt;a 
href=../CoreTypes/filterchain.html#linecontainslinecontains/agt;
  -  lt;contains value=import.quot;/gt;
  +  lt;contains value=quot;import.quot;/gt;
   lt;/linecontainsgt;
 lt;/filterchaingt;
   lt;/loadpropertiesgt;
  @@ -51,7 +55,7 @@
   Ant properties.
   hr
   
  -p align=centerCopyright copy; 2002 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2002-2003 Apache Software Foundation. All 
rights
   Reserved./p
   
   /body
  
  
  


cvs commit: ant/docs/manual/CoreTasks genkey.html

2003-03-19 Thread bodewig
bodewig 2003/03/19 01:11:11

  Modified:docs/manual/CoreTasks Tag: ANT_15_BRANCH genkey.html
  Log:
  Complete sentence with knowledge gained by raeding the source.
  
  PR: 14697
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.6.2.2   +7 -2  ant/docs/manual/CoreTasks/genkey.html
  
  Index: genkey.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/genkey.html,v
  retrieving revision 1.6.2.1
  retrieving revision 1.6.2.2
  diff -u -r1.6.2.1 -r1.6.2.2
  --- genkey.html   3 May 2002 09:40:28 -   1.6.2.1
  +++ genkey.html   19 Mar 2003 09:11:10 -  1.6.2.2
  @@ -76,7 +76,12 @@
 /tr
   /table
   
  -pAlternatively you can specify the distinguished name by creating a 
sub-element named dname and populating it with param elements that have a name 
and a value. When using the subelement it is automatically encoded properly and 
, are replace/p
  +pAlternatively you can specify the distinguished name by creating a
  +sub-element named dname and populating it with param elements that
  +have a name and a value. When using the subelement it is automatically
  +encoded properly and commas (quot;code,/codequot;) are replaced
  +with quot;code\,/codequot;./p
  +
   pThe following two examples are identical: /p
   
   h3Examples/h3
  @@ -96,7 +101,7 @@
   lt;/genkeygt;/code/pre
   /blockquote
   hr
  -p align=centerCopyright copy; 2000-2001 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2000-2001,2003 Apache Software 
Foundation. All rights
   Reserved./p
   
   /body
  
  
  


cvs commit: ant/docs/manual/CoreTasks genkey.html

2003-03-19 Thread bodewig
bodewig 2003/03/19 01:11:57

  Modified:docs/manual/CoreTasks genkey.html
  Log:
  Merge fix for bug 14697 from 1.5 branch
  
  Revision  ChangesPath
  1.8   +7 -2  ant/docs/manual/CoreTasks/genkey.html
  
  Index: genkey.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/genkey.html,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- genkey.html   1 Jun 2002 12:26:33 -   1.7
  +++ genkey.html   19 Mar 2003 09:11:57 -  1.8
  @@ -76,7 +76,12 @@
 /tr
   /table
   
  -pAlternatively you can specify the distinguished name by creating a 
sub-element named dname and populating it with param elements that have a name 
and a value. When using the subelement it is automatically encoded properly and 
, are replace/p
  +pAlternatively you can specify the distinguished name by creating a
  +sub-element named dname and populating it with param elements that
  +have a name and a value. When using the subelement it is automatically
  +encoded properly and commas (quot;code,/codequot;) are replaced
  +with quot;code\,/codequot;./p
  +
   pThe following two examples are identical: /p
   
   h3Examples/h3
  @@ -96,7 +101,7 @@
   lt;/genkeygt;/code/pre
   /blockquote
   hr
  -p align=centerCopyright copy; 2000-2001 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2000-2001,2003 Apache Software 
Foundation. All rights
   Reserved./p
   
   /body
  
  
  


cvs commit: ant/docs/manual using.html

2003-03-19 Thread bodewig
bodewig 2003/03/19 01:19:51

  Modified:docs/manual Tag: ANT_15_BRANCH using.html
  Log:
  Add an extra note about properties values being irrelevant for if/unless.
  
  PR: 14521
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.21.2.4  +8 -8  ant/docs/manual/using.html
  
  Index: using.html
  ===
  RCS file: /home/cvs/ant/docs/manual/using.html,v
  retrieving revision 1.21.2.3
  retrieving revision 1.21.2.4
  diff -u -r1.21.2.3 -r1.21.2.4
  --- using.html9 Aug 2002 08:39:47 -   1.21.2.3
  +++ using.html19 Mar 2003 09:19:50 -  1.21.2.4
  @@ -85,7 +85,9 @@
   (java version, OS, command-line property defines, etc.).  To make a target
   isense/i this property, you should add the codeif/code (or
   codeunless/code) attribute with the name of the property that the target
  -should react to. For example:/p
  +should react to. strongNote:/strong Ant will only check whether
  +the property has been set, the value doesn't matter.  A property set
  +to the empty string is still an existing property.  For example:/p
   blockquote
 prelt;target name=quot;build-module-Aquot; 
if=quot;module-A-presentquot;/gt;/pre
 prelt;target name=quot;build-own-fake-module-Aquot; 
unless=quot;module-A-presentquot;/gt;/pre
  @@ -147,18 +149,16 @@
   /table
   /p
   
  -A target name can be any alphanumeric string valid in the encoding of the XML
  +pA target name can be any alphanumeric string valid in the encoding of the 
XML
   file. The empty string quot;quot; is in this set, as is
   comma quot;,quot; and space quot; quot;.
   Please avoid using these, as they will not be supported in future Ant 
versions
   because of all the confusion they cause. IDE support of unusual target names,
  -or any target name containing spaces, varies with the IDE.
  +or any target name containing spaces, varies with the IDE./p
   
  -p
  -
  -Targets beginning with a hyphen such as codequot;-restartquot;/code
  +pTargets beginning with a hyphen such as codequot;-restartquot;/code
   are valid, and can be used
  -to name targets that should not be called directly from the command line.
  +to name targets that should not be called directly from the command line./p
   
   h3a name=tasksTasks/a/h3
   pA task is a piece of code that can be executed./p
  @@ -529,7 +529,7 @@
   structures as well./p
   
   hr
  -p align=centerCopyright copy; 2000-2002 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2000-2003 Apache Software Foundation. All 
rights
   Reserved./p
   
   /body
  
  
  


cvs commit: ant/src/testcases/org/apache/tools/tar - New directory

2003-03-19 Thread bodewig
bodewig 2003/03/19 02:01:44

  ant/src/testcases/org/apache/tools/tar - New directory


cvs commit: ant/src/testcases/org/apache/tools/tar TarEntryTest.java

2003-03-19 Thread bodewig
bodewig 2003/03/19 02:06:41

  Added:   src/testcases/org/apache/tools/tar TarEntryTest.java
  Log:
  Demonstrate bug 18105
  
  Revision  ChangesPath
  1.1  ant/src/testcases/org/apache/tools/tar/TarEntryTest.java
  
  Index: TarEntryTest.java
  ===
  /*
   * The Apache Software License, Version 1.1
   *
   * Copyright (c) 2003 The Apache Software Foundation.  All rights
   * reserved.
   *
   * Redistribution and use in source and binary forms, with or without
   * modification, are permitted provided that the following conditions
   * are met:
   *
   * 1. Redistributions of source code must retain the above copyright
   *notice, this list of conditions and the following disclaimer.
   *
   * 2. Redistributions in binary form must reproduce the above copyright
   *notice, this list of conditions and the following disclaimer in
   *the documentation and/or other materials provided with the
   *distribution.
   *
   * 3. The end-user documentation included with the redistribution, if
   *any, must include the following acknowlegement:
   *   This product includes software developed by the
   *Apache Software Foundation (http://www.apache.org/).
   *Alternately, this acknowlegement may appear in the software itself,
   *if and wherever such third-party acknowlegements normally appear.
   *
   * 4. The names Ant and Apache Software
   *Foundation must not be used to endorse or promote products derived
   *from this software without prior written permission. For written
   *permission, please contact [EMAIL PROTECTED]
   *
   * 5. Products derived from this software may not be called Apache
   *nor may Apache appear in their names without prior written
   *permission of the Apache Group.
   *
   * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
   * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
   * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
   * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
   * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
   * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
   * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
   * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
   * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
   * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
   * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
   * SUCH DAMAGE.
   * 
   *
   * This software consists of voluntary contributions made by many
   * individuals on behalf of the Apache Software Foundation.  For more
   * information on the Apache Software Foundation, please see
   * http://www.apache.org/.
   */
  
  package org.apache.tools.tar;
  
  import junit.framework.TestCase;
  
  /**
   * @since Ant 1.6
   */
  public class TarEntryTest extends TestCase {
  
  public TarEntryTest(String name) {
  super(name);
  }
  
  /**
   * demonstrates bug 18105 on OSes with os.name shorter than 7.
   */
  public void testFileConstructor() {
  new TarEntry(new java.io.File(/foo));
  }
  }
  
  
  


cvs commit: ant/src/main/org/apache/tools/tar TarEntry.java

2003-03-19 Thread bodewig
bodewig 2003/03/19 02:09:38

  Modified:.WHATSNEW
   src/main/org/apache/tools/tar TarEntry.java
  Log:
  TarEntry's File-constructor didn't work for many OSes.
  
  PR: 18105
  
  At the same time, make the OS check Locale independent.
  
  Revision  ChangesPath
  1.367 +4 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.366
  retrieving revision 1.367
  diff -u -r1.366 -r1.367
  --- WHATSNEW  14 Mar 2003 16:01:03 -  1.366
  +++ WHATSNEW  19 Mar 2003 10:09:38 -  1.367
  @@ -66,6 +66,10 @@
   * exec output and error streams can now be redirected independently
 to either a property or a file (or both)
   
  +* TarEntry's File-arg constructor would fail with a 
  +  StringIndexOutOfBoundsException on all OSes where os.name is shorter
  +  than seven characters.  Bugzilla Report 18105.
  +
   Other changes:
   --
   * The filesetmanifest attribute of jar has been reenabled.
  
  
  
  1.15  +5 -6  ant/src/main/org/apache/tools/tar/TarEntry.java
  
  Index: TarEntry.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/tar/TarEntry.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- TarEntry.java 10 Feb 2003 14:14:42 -  1.14
  +++ TarEntry.java 19 Mar 2003 10:09:38 -  1.15
  @@ -1,7 +1,7 @@
   /*
* The Apache Software License, Version 1.1
*
  - * Copyright (c) 2000-2002 The Apache Software Foundation.  All rights
  + * Copyright (c) 2000-2003 The Apache Software Foundation.  All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
  @@ -61,6 +61,7 @@
   
   import java.io.File;
   import java.util.Date;
  +import java.util.Locale;
   
   /**
* This class represents an entry in a Tar archive. It consists
  @@ -200,16 +201,14 @@
   this.file = file;
   
   String name = file.getPath();
  -String osname = System.getProperty(os.name);
  +String osname = System.getProperty(os.name).toLowerCase(Locale.US);
   
   if (osname != null) {
   
   // Strip off drive letters!
   // REVIEW Would a better check be (File.separator == '\')?
  -String win32Prefix = Windows;
  -String prefix = osname.substring(0, win32Prefix.length());
   
  -if (prefix.equalsIgnoreCase(win32Prefix)) {
  +if (osname.startsWith(windows)) {
   if (name.length()  2) {
   char ch1 = name.charAt(0);
   char ch2 = name.charAt(1);
  @@ -220,7 +219,7 @@
   name = name.substring(2);
   } 
   } 
  -} else if (osname.toLowerCase().indexOf(netware)  -1) {
  +} else if (osname.indexOf(netware)  -1) {
   int colon = name.indexOf(':');
   if (colon != -1) {
   name = name.substring(colon + 1);
  
  
  


cvs commit: ant/docs/manual/OptionalTasks cab.html

2003-03-19 Thread bodewig
bodewig 2003/03/19 02:39:42

  Modified:docs/manual/OptionalTasks Tag: ANT_15_BRANCH cab.html
  Log:
  Document that cab supports nested filesets
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.5.2.3   +8 -1  ant/docs/manual/OptionalTasks/cab.html
  
  Index: cab.html
  ===
  RCS file: /home/cvs/ant/docs/manual/OptionalTasks/cab.html,v
  retrieving revision 1.5.2.2
  retrieving revision 1.5.2.3
  diff -u -r1.5.2.2 -r1.5.2.3
  --- cab.html  20 Jun 2002 09:40:31 -  1.5.2.2
  +++ cab.html  19 Mar 2003 10:39:42 -  1.5.2.3
  @@ -91,6 +91,13 @@
   td valign=top align=centerNo/td
 /tr
   /table
  +h3Parameters specified as nested elements/h3
  +h4fileset/h4
  +
  +pThe cab task supports any number of nested a
  +href=../CoreTypes/fileset.htmlcodelt;filesetgt;/code/a
  +elements to specify the files to be included in the archive./p
  +
   h3Examples/h3
   blockquotepre
   lt;cab cabfile=quot;${dist}/manual.cabquot;
  @@ -122,7 +129,7 @@
   excluded. Output from the cabarc tool is displayed in the build
   output./p
   hr
  -p align=centerCopyright copy; 2000-2002 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2000-2003 Apache Software Foundation. All 
rights
   Reserved./p
   
   /body
  
  
  


cvs commit: ant/xdocs projects.xml

2003-03-20 Thread bodewig
bodewig 2003/03/20 00:00:14

  Modified:docs projects.html
   xdocsprojects.xml
  Log:
  AntDoc has moved
  
  Revision  ChangesPath
  1.31  +2 -2  ant/docs/projects.html
  
  Index: projects.html
  ===
  RCS file: /home/cvs/ant/docs/projects.html,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -r1.30 -r1.31
  --- projects.html 18 Mar 2003 16:11:37 -  1.30
  +++ projects.html 20 Mar 2003 08:00:11 -  1.31
  @@ -357,7 +357,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://mapage.noos.fr/antdoc;http://mapage.noos.fr/antdoc/a
  +  a href=http://antdoc.free.fr/;http://antdoc.free.fr//a
 /td
 /tr
 tr
  @@ -377,7 +377,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  At the moment, no license is being attached to the tool.
  +  The Apache Software License
 /td
 /tr
   /table
  
  
  
  1.9   +2 -2  ant/xdocs/projects.xml
  
  Index: projects.xml
  ===
  RCS file: /home/cvs/ant/xdocs/projects.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- projects.xml  18 Mar 2003 16:11:37 -  1.8
  +++ projects.xml  20 Mar 2003 08:00:14 -  1.9
  @@ -88,7 +88,7 @@
 /tr
 tr
   thURL:/th
  -tda 
href=http://mapage.noos.fr/antdoc;http://mapage.noos.fr/antdoc/a/td
  +tda 
href=http://antdoc.free.fr/;http://antdoc.free.fr//a/td
 /tr
 tr
   thContact:/th
  @@ -96,7 +96,7 @@
 /tr
 tr
   thLicense:/th
  -tdAt the moment, no license is being attached to the tool./td
  +tdThe Apache Software License/td
 /tr
   /table
 /subsection
  
  
  


cvs commit: ant/xdocs external.xml projects.xml

2003-03-20 Thread bodewig
bodewig 2003/03/20 00:09:32

  Modified:docs Tag: ANT_15_BRANCH external.html projects.html
   xdocsTag: ANT_15_BRANCH external.xml projects.xml
  Log:
  sync with HEAD
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.48.2.31 +167 -6ant/docs/external.html
  
  Index: external.html
  ===
  RCS file: /home/cvs/ant/docs/external.html,v
  retrieving revision 1.48.2.30
  retrieving revision 1.48.2.31
  diff -u -r1.48.2.30 -r1.48.2.31
  --- external.html 7 Mar 2003 12:36:18 -   1.48.2.30
  +++ external.html 20 Mar 2003 08:09:27 -  1.48.2.31
  @@ -410,7 +410,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  Ant 1.2 to 1.4.1
  +  Ant 1.4.1 and later
 /td
 /tr
 tr
  @@ -909,7 +909,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://www.discore.com/oz/new/index.htm;http://www.discore.com/oz/new/index.htm/a
  +  a 
href=http://greebo.sourceforge.net/;http://greebo.sourceforge.net//a
 /td
 /tr
 tr
  @@ -919,7 +919,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a href=mailto:[EMAIL PROTECTED]Ozben Evren/a
  +  a href=http://sourceforge.net/mail/?group_id=73733;project 
mailing lists/a
 /td
 /tr
 tr
  @@ -1102,7 +1102,7 @@
 /font
   /td/tr
 /table
  -pThere are three different sets of tasks to help 
build a href=http://java.sun.com/j2me/;Java 2 Platform, Micro
  +pThere are four different sets of tasks to help 
build a href=http://java.sun.com/j2me/;Java 2 Platform, Micro
   Edition/a (J2ME) applications./p
   pThis set supports CLDC and the K Virtual 
Machine (KVM):/p
 table class=ForrestTable 
cellspacing=1 cellpadding=4
  @@ -1239,6 +1239,56 @@
 /td
 /tr
   /table
  +pAntic is a freely available task for 
packaging J2ME
  +applications. It produces both the Jar and Jad files in a
  +single step. This allows *all* entries to be correclty set in
  +the jad file, including the size of the jar file that is
  +produced. This task has been used and tested extensively with
  +Sun's Wireless Toolkit and also the Nokia SDK and
  +emulators./p
  +  table class=ForrestTable 
cellspacing=1 cellpadding=4
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Compatibility:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Ant 1.5
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  URL:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a 
href=http://www.smartkey.co.uk/antic.html;www.smartkey.co.uk/a
  +
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Contact:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a href=mailto:[EMAIL PROTECTED]smartkey.co.uk/a
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  License:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  GNU General Public License
  +  /td
  +  /tr
  +/table
   br/
 a name=Jacson/a
 table border=0 cellspacing=0 cellpadding=2 width=100%
  @@ -1249,8 +1299,8 @@
   /td/tr
 /table
   pJacson is a configurable and plugable tool (much 
like Ant
  - itself) to create filters for text (line based) files without
  - programming./p
  +itself) to create filters for text (line based) files without
  +programming./p
 table class=ForrestTable 
cellspacing=1 cellpadding=4
 tr
 th colspan=1 rowspan=1
  @@ -1426,6 +1476,60 @@
 /tr
   /table
   br/
  +  a name=Java2Html/a
  +  table border=0 cellspacing=0 cellpadding=2 width=100%
  +trtd bgcolor=#4C6C8F
  +  font color=#ff face=arial,helvetica,sanserif

cvs commit: ant/docs/manual developlist.html

2003-03-20 Thread bodewig
bodewig 2003/03/20 00:33:23

  Modified:docs/manual developlist.html
  Log:
  Typo
  
  Revision  ChangesPath
  1.4   +1 -1  ant/docs/manual/developlist.html
  
  Index: developlist.html
  ===
  RCS file: /home/cvs/ant/docs/manual/developlist.html,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- developlist.html  1 Jun 2002 12:26:32 -   1.3
  +++ developlist.html  20 Mar 2003 08:33:21 -  1.4
  @@ -13,7 +13,7 @@
   h3Developing with Ant/h3
   
   a href=develop.html#writingowntaskWriting Your Own Task/abr
  -a href=base_task_classes.htmlTasks Designed for Extensiton/abr
  +a href=base_task_classes.htmlTasks Designed for Extension/abr
   a href=develop.html#buildeventsBuild Events/abr
   a href=develop.html#integrationSource-code Integration/abr
   a href=inputhandler.htmlInputHandler/abr
  
  
  


cvs commit: ant/docs/manual developlist.html

2003-03-20 Thread bodewig
bodewig 2003/03/20 00:33:37

  Modified:docs/manual Tag: ANT_15_BRANCH developlist.html
  Log:
  Typo
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.2.2.3   +1 -1  ant/docs/manual/developlist.html
  
  Index: developlist.html
  ===
  RCS file: /home/cvs/ant/docs/manual/developlist.html,v
  retrieving revision 1.2.2.2
  retrieving revision 1.2.2.3
  diff -u -r1.2.2.2 -r1.2.2.3
  --- developlist.html  30 May 2002 23:59:55 -  1.2.2.2
  +++ developlist.html  20 Mar 2003 08:33:37 -  1.2.2.3
  @@ -13,7 +13,7 @@
   h3Developing with Ant/h3
   
   a href=develop.html#writingowntaskWriting Your Own Task/abr
  -a href=base_task_classes.htmlTasks Designed for Extensiton/abr
  +a href=base_task_classes.htmlTasks Designed for Extension/abr
   a href=develop.html#buildeventsBuild Events/abr
   a href=develop.html#integrationSource-code Integration/abr
   a href=inputhandler.htmlInputHandler/abr
  
  
  


cvs commit: ant/docs/manual/CoreTasks pathconvert.html

2003-03-20 Thread bodewig
bodewig 2003/03/20 01:14:41

  Modified:docs/manual/CoreTasks pathconvert.html
  Log:
  Typo
  
  Revision  ChangesPath
  1.12  +1 -1  ant/docs/manual/CoreTasks/pathconvert.html
  
  Index: pathconvert.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/pathconvert.html,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- pathconvert.html  14 Mar 2003 16:01:03 -  1.11
  +++ pathconvert.html  20 Mar 2003 09:14:41 -  1.12
  @@ -67,7 +67,7 @@
   td valign=topWhat to convert, given as a
   a href=../using.html#referencesreference/a to a
   codelt;pathgt;/code, codelt;filesetgt;/code,
  -codelt;dirsetgt;/code, or codelt;filesetgt;/code
  +codelt;dirsetgt;/code, or codelt;filelistgt;/code
   defined elsewhere/td
   td valign=top align=centerNo; if omitted, a nested
   codelt;pathgt;/code element must be supplied./td
  
  
  


cvs commit: ant/xdocs external.xml

2003-03-25 Thread bodewig
bodewig 2003/03/25 00:43:34

  Modified:docs external.html
   xdocsexternal.xml
  Log:
  Add pointers to JBuilder 8 Enterprise and Gel.
  
  Submitted by: Paul King king at asert dot com dot au
  
  Revision  ChangesPath
  1.99  +108 -0ant/docs/external.html
  
  Index: external.html
  ===
  RCS file: /home/cvs/ant/docs/external.html,v
  retrieving revision 1.98
  retrieving revision 1.99
  diff -u -r1.98 -r1.99
  --- external.html 18 Mar 2003 16:34:55 -  1.98
  +++ external.html 25 Mar 2003 08:43:34 -  1.99
  @@ -3361,6 +3361,59 @@
 /tr
   /table
   br/
  +  a name=Gel/a
  +  table border=0 cellspacing=0 cellpadding=2 width=100%
  +trtd bgcolor=#4C6C8F
  +  font color=#ff face=arial,helvetica,sanserif
  +strongGel/strong
  +  /font
  +/td/tr
  +  /table
  +pJava IDE with support for Ant.  Gel is a native 
Microsoft
  +Windows software./p
  +  table class=ForrestTable 
cellspacing=1 cellpadding=4
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Compatibility:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Ant 1.4 and above
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  URL:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a 
href=http://www.gexperts.com/gel.html;http://www.gexperts.com/gel.html/a
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Contact:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a href=http://groups.yahoo.com/group/gelide/;Project Mailing 
List/a
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  License:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Freeware
  +  /td
  +  /tr
  +/table
  +br/
 a name=HP RadPak/a
 table border=0 cellspacing=0 cellpadding=2 width=100%
   trtd bgcolor=#4C6C8F
  @@ -3449,6 +3502,61 @@
 td colspan=1 rowspan=1
 valign=top align=left
 a href=mailto:[EMAIL PROTECTED][EMAIL PROTECTED]/a
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  License:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Commercial
  +  /td
  +  /tr
  +/table
  +br/
  +  a name=JBuilder 8 Enterprise/a
  +  table border=0 cellspacing=0 cellpadding=2 width=100%
  +trtd bgcolor=#4C6C8F
  +  font color=#ff face=arial,helvetica,sanserif
  +strongJBuilder 8 Enterprise/strong
  +  /font
  +/td/tr
  +  /table
  +pJBuilder 8 Enterprise and Performance Bundle
  +come with built-in Ant support.  JBuilder 8 Personal and SE
  +don't support Ant directly, but a href=#AntRunneran
  +OpenTool/a is available for them./p
  +  table class=ForrestTable 
cellspacing=1 cellpadding=4
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Compatibility:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Bundles Ant 1.5.1
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  URL:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a 
href=http://www.borland.com/jbuilder/index.html;http://www.borland.com/jbuilder/index.html/a
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Contact:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a href=mailto:[EMAIL PROTECTED][EMAIL PROTECTED]/a
 /td
 /tr
 tr
  
  
  
  1.76  +52 -0 ant/xdocs/external.xml
  
  Index: external.xml
  ===
  RCS file: /home/cvs/ant/xdocs/external.xml,v

cvs commit: ant/xdocs external.xml

2003-03-25 Thread bodewig
bodewig 2003/03/25 00:44:34

  Modified:docs Tag: ANT_15_BRANCH external.html
   xdocsTag: ANT_15_BRANCH external.xml
  Log:
  Merge with HEAD
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.48.2.32 +108 -0ant/docs/external.html
  
  Index: external.html
  ===
  RCS file: /home/cvs/ant/docs/external.html,v
  retrieving revision 1.48.2.31
  retrieving revision 1.48.2.32
  diff -u -r1.48.2.31 -r1.48.2.32
  --- external.html 20 Mar 2003 08:09:27 -  1.48.2.31
  +++ external.html 25 Mar 2003 08:44:33 -  1.48.2.32
  @@ -3361,6 +3361,59 @@
 /tr
   /table
   br/
  +  a name=Gel/a
  +  table border=0 cellspacing=0 cellpadding=2 width=100%
  +trtd bgcolor=#4C6C8F
  +  font color=#ff face=arial,helvetica,sanserif
  +strongGel/strong
  +  /font
  +/td/tr
  +  /table
  +pJava IDE with support for Ant.  Gel is a native 
Microsoft
  +Windows software./p
  +  table class=ForrestTable 
cellspacing=1 cellpadding=4
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Compatibility:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Ant 1.4 and above
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  URL:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a 
href=http://www.gexperts.com/gel.html;http://www.gexperts.com/gel.html/a
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Contact:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a href=http://groups.yahoo.com/group/gelide/;Project Mailing 
List/a
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  License:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Freeware
  +  /td
  +  /tr
  +/table
  +br/
 a name=HP RadPak/a
 table border=0 cellspacing=0 cellpadding=2 width=100%
   trtd bgcolor=#4C6C8F
  @@ -3449,6 +3502,61 @@
 td colspan=1 rowspan=1
 valign=top align=left
 a href=mailto:[EMAIL PROTECTED][EMAIL PROTECTED]/a
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  License:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Commercial
  +  /td
  +  /tr
  +/table
  +br/
  +  a name=JBuilder 8 Enterprise/a
  +  table border=0 cellspacing=0 cellpadding=2 width=100%
  +trtd bgcolor=#4C6C8F
  +  font color=#ff face=arial,helvetica,sanserif
  +strongJBuilder 8 Enterprise/strong
  +  /font
  +/td/tr
  +  /table
  +pJBuilder 8 Enterprise and Performance Bundle
  +come with built-in Ant support.  JBuilder 8 Personal and SE
  +don't support Ant directly, but a href=#AntRunneran
  +OpenTool/a is available for them./p
  +  table class=ForrestTable 
cellspacing=1 cellpadding=4
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Compatibility:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  Bundles Ant 1.5.1
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  URL:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a 
href=http://www.borland.com/jbuilder/index.html;http://www.borland.com/jbuilder/index.html/a
  +  /td
  +  /tr
  +  tr
  +  th colspan=1 rowspan=1
  +  valign=top align=left
  +  Contact:
  +  /th
  +  td colspan=1 rowspan=1
  +  valign=top align=left
  +  a href=mailto:[EMAIL PROTECTED][EMAIL PROTECTED]/a
 /td
 /tr
 tr
  
  
  
  No   revision
  
  
  No   revision
  
  
  1.35.2.31 +52 -0 ant/xdocs/external.xml
  
  Index

cvs commit: ant/xdocs external.xml

2003-03-25 Thread bodewig
bodewig 2003/03/25 01:04:52

  Modified:docs external.html
   xdocsexternal.xml
  Log:
  Fix some URLs
  
  Revision  ChangesPath
  1.100 +13 -13ant/docs/external.html
  
  Index: external.html
  ===
  RCS file: /home/cvs/ant/docs/external.html,v
  retrieving revision 1.99
  retrieving revision 1.100
  diff -u -r1.99 -r1.100
  --- external.html 25 Mar 2003 08:43:34 -  1.99
  +++ external.html 25 Mar 2003 09:04:51 -  1.100
  @@ -230,7 +230,7 @@
 /font
   /td/tr
 /table
  -pa href=http://aspectj.org;AspectJ/a is an
  +pa 
href=http://www.eclipse.org/aspectj/;AspectJ/a is an
 aspect-oriented extension to Java.  This task compiles a
 source tree using the AspectJ compiler -- AJC./p
 table class=ForrestTable 
cellspacing=1 cellpadding=4
  @@ -251,7 +251,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a href=http://aspectj.org/dl;http://aspectj.org/dl/a
  +  a 
href=http://www.eclipse.org/aspectj/;http://www.eclipse.org/aspectj//a
 /td
 /tr
 tr
  @@ -261,7 +261,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a href=mailto:[EMAIL PROTECTED][EMAIL PROTECTED]/a
  +  a href=http://www.eclipse.org/aspectj/;project mailing lists/a
 /td
 /tr
 tr
  @@ -362,7 +362,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a href=http://aft.sourceforge.net;http://aft.sourceforge.net/a
  +  a 
href=http://aft.sourceforge.net/;http://aft.sourceforge.net//a
 /td
 /tr
 tr
  @@ -586,7 +586,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://www.thecortex.net/clover;http://www.thecortex.net/clover/a
  +  a 
href=http://www.thecortex.net/clover/;http://www.thecortex.net/clover//a
 /td
 /tr
 tr
  @@ -799,7 +799,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://ant-doxygen.sourceforge.net;http://ant-doxygen.sourceforge.net/a
  +  a 
href=http://ant-doxygen.sourceforge.net/;http://ant-doxygen.sourceforge.net//a
 /td
 /tr
 tr
  @@ -1264,7 +1264,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://www.smartkey.co.uk/antic.html;www.smartkey.co.uk/a
  +  a 
href=http://www.smartkey.co.uk/antic.html;http://www.smartkey.co.uk/antic.html/a
   
 /td
 /tr
  @@ -1320,7 +1320,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://jacson.sourceforge.net;http://jacson.sourceforge.net/a
  +  a 
href=http://jacson.sourceforge.net/;http://jacson.sourceforge.net//a
 /td
 /tr
 tr
  @@ -1373,7 +1373,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://jalopy.sourceforge.net;http://jalopy.sourceforge.net/a
  +  a 
href=http://jalopy.sourceforge.net/;http://jalopy.sourceforge.net//a
 /td
 /tr
 tr
  @@ -1505,7 +1505,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a href=http://www.java2html.de;http://www.java2html.de/a
  +  a href=http://www.java2html.de/;http://www.java2html.de//a
 /td
 /tr
 tr
  @@ -2958,7 +2958,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://www.yworks.com/products/yguard;http://www.yworks.com/products/yguard/a
  +  a 
href=http://www.yworks.com/en/products_yguard_about.htm;http://www.yworks.com/en/products_yguard_about.htm/a
 /td
 /tr
 tr
  @@ -3232,7 +3232,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://www.dieter-bogdoll.de/java/AntRunner/;http://www.dieter-bogdoll.de/java/AntRunner//a
  +  a 
href=http://antrunner.sourceforge.net/;http://antrunner.sourceforge.net//a
 /td
 /tr
 tr
  @@ -3336,7 +3336,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a href=http://www.eclipse.org;http://www.eclipse.org/a
  +  a href=http://www.eclipse.org/;http

cvs commit: ant/xdocs external.xml

2003-03-25 Thread bodewig
bodewig 2003/03/25 01:05:40

  Modified:docs Tag: ANT_15_BRANCH external.html
   xdocsTag: ANT_15_BRANCH external.xml
  Log:
  Fix some URLs
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.48.2.33 +13 -13ant/docs/external.html
  
  Index: external.html
  ===
  RCS file: /home/cvs/ant/docs/external.html,v
  retrieving revision 1.48.2.32
  retrieving revision 1.48.2.33
  diff -u -r1.48.2.32 -r1.48.2.33
  --- external.html 25 Mar 2003 08:44:33 -  1.48.2.32
  +++ external.html 25 Mar 2003 09:05:39 -  1.48.2.33
  @@ -230,7 +230,7 @@
 /font
   /td/tr
 /table
  -pa href=http://aspectj.org;AspectJ/a is an
  +pa 
href=http://www.eclipse.org/aspectj/;AspectJ/a is an
 aspect-oriented extension to Java.  This task compiles a
 source tree using the AspectJ compiler -- AJC./p
 table class=ForrestTable 
cellspacing=1 cellpadding=4
  @@ -251,7 +251,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a href=http://aspectj.org/dl;http://aspectj.org/dl/a
  +  a 
href=http://www.eclipse.org/aspectj/;http://www.eclipse.org/aspectj//a
 /td
 /tr
 tr
  @@ -261,7 +261,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a href=mailto:[EMAIL PROTECTED][EMAIL PROTECTED]/a
  +  a href=http://www.eclipse.org/aspectj/;project mailing lists/a
 /td
 /tr
 tr
  @@ -362,7 +362,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a href=http://aft.sourceforge.net;http://aft.sourceforge.net/a
  +  a 
href=http://aft.sourceforge.net/;http://aft.sourceforge.net//a
 /td
 /tr
 tr
  @@ -586,7 +586,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://www.thecortex.net/clover;http://www.thecortex.net/clover/a
  +  a 
href=http://www.thecortex.net/clover/;http://www.thecortex.net/clover//a
 /td
 /tr
 tr
  @@ -799,7 +799,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://ant-doxygen.sourceforge.net;http://ant-doxygen.sourceforge.net/a
  +  a 
href=http://ant-doxygen.sourceforge.net/;http://ant-doxygen.sourceforge.net//a
 /td
 /tr
 tr
  @@ -1264,7 +1264,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://www.smartkey.co.uk/antic.html;www.smartkey.co.uk/a
  +  a 
href=http://www.smartkey.co.uk/antic.html;http://www.smartkey.co.uk/antic.html/a
   
 /td
 /tr
  @@ -1320,7 +1320,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://jacson.sourceforge.net;http://jacson.sourceforge.net/a
  +  a 
href=http://jacson.sourceforge.net/;http://jacson.sourceforge.net//a
 /td
 /tr
 tr
  @@ -1373,7 +1373,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://jalopy.sourceforge.net;http://jalopy.sourceforge.net/a
  +  a 
href=http://jalopy.sourceforge.net/;http://jalopy.sourceforge.net//a
 /td
 /tr
 tr
  @@ -1505,7 +1505,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a href=http://www.java2html.de;http://www.java2html.de/a
  +  a href=http://www.java2html.de/;http://www.java2html.de//a
 /td
 /tr
 tr
  @@ -2958,7 +2958,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://www.yworks.com/products/yguard;http://www.yworks.com/products/yguard/a
  +  a 
href=http://www.yworks.com/en/products_yguard_about.htm;http://www.yworks.com/en/products_yguard_about.htm/a
 /td
 /tr
 tr
  @@ -3232,7 +3232,7 @@
 /th
 td colspan=1 rowspan=1
 valign=top align=left
  -  a 
href=http://www.dieter-bogdoll.de/java/AntRunner/;http://www.dieter-bogdoll.de/java/AntRunner//a
  +  a 
href=http://antrunner.sourceforge.net/;http://antrunner.sourceforge.net//a
 /td
 /tr
 tr
  @@ -3336,7 +3336,7 @@
 /th
 td colspan=1 rowspan=1
 valign

cvs commit: ant/src/main/org/apache/tools/ant/taskdefs Sync.java defaults.properties

2003-03-25 Thread bodewig
bodewig 2003/03/25 01:31:00

  Modified:.WHATSNEW
   src/main/org/apache/tools/ant/taskdefs defaults.properties
  Added:   src/main/org/apache/tools/ant/taskdefs Sync.java
  Log:
  New task sync.
  
  PR: 12632
  Submitted by:   Dominique Devienne ddevienne at lgc dot com
  Dan Armbrust daniel dot armbrust at mayo dot edu
  
  Revision  ChangesPath
  1.370 +2 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.369
  retrieving revision 1.370
  diff -u -r1.369 -r1.370
  --- WHATSNEW  20 Mar 2003 09:10:53 -  1.369
  +++ WHATSNEW  25 Mar 2003 09:30:59 -  1.370
  @@ -172,6 +172,8 @@
   * cab's basedir attribute is now optional if you specify nested
 filesets.  Bugzilla Report 18046.
   
  +* New task sync that synchronizes two directory trees.
  +
   Changes from Ant 1.5.2 to Ant 1.5.3
   ===
   
  
  
  
  1.143 +1 -0  
ant/src/main/org/apache/tools/ant/taskdefs/defaults.properties
  
  Index: defaults.properties
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/defaults.properties,v
  retrieving revision 1.142
  retrieving revision 1.143
  diff -u -r1.142 -r1.143
  --- defaults.properties   14 Mar 2003 00:42:04 -  1.142
  +++ defaults.properties   25 Mar 2003 09:30:59 -  1.143
  @@ -74,6 +74,7 @@
   import=org.apache.tools.ant.taskdefs.ImportTask
   whichresource=org.apache.tools.ant.taskdefs.WhichResource
   subant=org.apache.tools.ant.taskdefs.SubAnt
  +sync=org.apache.tools.ant.taskdefs.Sync
   
   # optional tasks
   image=org.apache.tools.ant.taskdefs.optional.image.Image
  
  
  
  1.1  ant/src/main/org/apache/tools/ant/taskdefs/Sync.java
  
  Index: Sync.java
  ===
  /*
   * The Apache Software License, Version 1.1
   *
   * Copyright (c) 2003 The Apache Software Foundation.  All rights
   * reserved.
   *
   * Redistribution and use in source and binary forms, with or without
   * modification, are permitted provided that the following conditions
   * are met:
   *
   * 1. Redistributions of source code must retain the above copyright
   *notice, this list of conditions and the following disclaimer.
   *
   * 2. Redistributions in binary form must reproduce the above copyright
   *notice, this list of conditions and the following disclaimer in
   *the documentation and/or other materials provided with the
   *distribution.
   *
   * 3. The end-user documentation included with the redistribution, if
   *any, must include the following acknowlegement:
   *   This product includes software developed by the
   *Apache Software Foundation (http://www.apache.org/).
   *Alternately, this acknowlegement may appear in the software itself,
   *if and wherever such third-party acknowlegements normally appear.
   *
   * 4. The names Ant and Apache Software
   *Foundation must not be used to endorse or promote products derived
   *from this software without prior written permission. For written
   *permission, please contact [EMAIL PROTECTED]
   *
   * 5. Products derived from this software may not be called Apache
   *nor may Apache appear in their names without prior written
   *permission of the Apache Group.
   *
   * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
   * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
   * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
   * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
   * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
   * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
   * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
   * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
   * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
   * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
   * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
   * SUCH DAMAGE.
   * 
   *
   * This software consists of voluntary contributions made by many
   * individuals on behalf of the Apache Software Foundation.  For more
   * information on the Apache Software Foundation, please see
   * http://www.apache.org/.
   */
  
  /*
   * This code is based on code Copyright (c) 2002, Landmark Graphics
   * Corp that has been kindly donated to the Apache Software
   * Foundation.
   */
  
  package org.apache.tools.ant.taskdefs;
  
  import java.io.File;
  
  import java.util.Hashtable;
  
  import org.apache.tools.ant.BuildException;
  import

cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/unix Symlink.java

2003-03-26 Thread bodewig
bodewig 2003/03/26 07:50:28

  Modified:src/main/org/apache/tools/ant/taskdefs/optional/unix
Symlink.java
  Log:
  Fix javadocs.
  
  PR: 17143
  Submitted by: Gus Heck
  
  Revision  ChangesPath
  1.4   +7 -7  
ant/src/main/org/apache/tools/ant/taskdefs/optional/unix/Symlink.java
  
  Index: Symlink.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/unix/Symlink.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- Symlink.java  10 Feb 2003 14:14:28 -  1.3
  +++ Symlink.java  26 Mar 2003 15:50:28 -  1.4
  @@ -141,12 +141,12 @@
* absolute paths. On non-unix systems this may cause false positives. 
* Furthermore, any operating system on which the command 
* codeln -s link resource/code is not a valid command on the comandline 
  - * will not be able to use action=single or action=multi action=record
  - * should still work. Finally, the lack of support for symlinks in Java
  - * means that all links are recorded as links to the 
  - * strongcanonical/strong resource name. Therefore the link:
  - * codelink -- subdir/dir/../foo.bar/code will be recorded as
  - * codelink=subdir/foo.bar/code and restored as 
  + * will not be able to use action= delete, action=single or 
  + * action=recreate, but action=record should still work. Finally, the 
  + * lack of support for symlinks in Java means that all links are recorded 
  + * as links to the strongcanonical/strong resource name. Therefore 
  + * the link: codelink -- subdir/dir/../foo.bar/code will be recorded 
  + * as codelink=subdir/foo.bar/code and restored as 
* codelink -- subdir/foo.bar/code
*
* @version $Revision$
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/starteam TreeBasedTask.java

2003-03-27 Thread bodewig
bodewig 2003/03/27 00:02:15

  Modified:.WHATSNEW
   src/main/org/apache/tools/ant/taskdefs/optional/starteam
TreeBasedTask.java
  Log:
  Make starteam checkout handle deleted labels correctly.
  
  PR: 17646
  Submitted by: Brian Brooks brian dot brooks at metavante dot com
  Reviewed by:  Steve Cohen
  
  Revision  ChangesPath
  1.371 +2 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.370
  retrieving revision 1.371
  diff -u -r1.370 -r1.371
  --- WHATSNEW  25 Mar 2003 09:30:59 -  1.370
  +++ WHATSNEW  27 Mar 2003 08:02:15 -  1.371
  @@ -70,6 +70,8 @@
 StringIndexOutOfBoundsException on all OSes where os.name is shorter
 than seven characters.  Bugzilla Report 18105.
   
  +* starteam checkout can now handle deleted labels.  Bugzilla Report 17646.
  +
   Other changes:
   --
   * The filesetmanifest attribute of jar has been reenabled.
  
  
  
  1.16  +1 -1  
ant/src/main/org/apache/tools/ant/taskdefs/optional/starteam/TreeBasedTask.java
  
  Index: TreeBasedTask.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/starteam/TreeBasedTask.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -r1.15 -r1.16
  --- TreeBasedTask.java11 Feb 2003 11:57:27 -  1.15
  +++ TreeBasedTask.java27 Mar 2003 08:02:15 -  1.16
  @@ -566,7 +566,7 @@
   for (int i = 0; i  allLabels.length; i++) {
   Label stLabel = allLabels[i];
   log(checking label  + stLabel.getName(), Project.MSG_DEBUG);
  -if (stLabel.getName().equals(this.label)) {
  +if (stLabel != null  !stLabel.isDeleted()  
stLabel.getName().equals(this.label)) {
   if (!stLabel.isRevisionLabel()  !stLabel.isViewLabel()) {
   throw new BuildException(Unexpected label type.);
   }
  
  
  


cvs commit: ant/src/script ant

2003-03-27 Thread bodewig
bodewig 2003/03/27 00:24:21

  Modified:.WHATSNEW
   src/script ant
  Log:
  Make wrapper script work if ant is a relative symlink and ANT_HOME
  isn't set.
  
  PR: 17721
  Submitted by: Martin Frost martin at macrospace dot com
  
  Revision  ChangesPath
  1.372 +3 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.371
  retrieving revision 1.372
  diff -u -r1.371 -r1.372
  --- WHATSNEW  27 Mar 2003 08:02:15 -  1.371
  +++ WHATSNEW  27 Mar 2003 08:24:21 -  1.372
  @@ -72,6 +72,9 @@
   
   * starteam checkout can now handle deleted labels.  Bugzilla Report 17646.
   
  +* The Unix wrapper script failed if you invoked it as a relative
  +  symlink and ANT_HOME has not been set.  Bugzilla Report 17721.
  +
   Other changes:
   --
   * The filesetmanifest attribute of jar has been reenabled.
  
  
  
  1.35  +1 -1  ant/src/script/ant
  
  Index: ant
  ===
  RCS file: /home/cvs/ant/src/script/ant,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -r1.34 -r1.35
  --- ant   7 Mar 2003 08:42:26 -   1.34
  +++ ant   27 Mar 2003 08:24:21 -  1.35
  @@ -51,7 +51,7 @@
 while [ -h $PRG ] ; do
   ls=`ls -ld $PRG`
   link=`expr $ls : '.*- \(.*\)$'`
  -if expr $link : '.*/.*'  /dev/null; then
  +if expr $link : '/.*'  /dev/null; then
PRG=$link
   else
PRG=`dirname $PRG`/$link
  
  
  


cvs commit: ant/src/testcases/org/apache/tools/ant/taskdefs ZipTest.java

2003-03-27 Thread bodewig
bodewig 2003/03/27 01:43:49

  Modified:src/etc/testcases/taskdefs zip.xml
   src/testcases/org/apache/tools/ant/taskdefs ZipTest.java
  Log:
  Demonstrate bug 18403
  
  Revision  ChangesPath
  1.11  +7 -0  ant/src/etc/testcases/taskdefs/zip.xml
  
  Index: zip.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/taskdefs/zip.xml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- zip.xml   5 Feb 2003 10:43:07 -   1.10
  +++ zip.xml   27 Mar 2003 09:43:48 -  1.11
  @@ -95,6 +95,13 @@
update=true /
 /target
   
  +  !-- Bugzilla Report 18403 --
  +  target name=testPrefixAddsDir
  +zip destfile=test3.zip filesonly=false
  +  zipfileset dir=. prefix=test includes=zip.xml/
  +/zip
  +  /target
  +
 target name=cleanup
   delete file=test3.zip/
   delete file=test4.zip/
  
  
  
  1.13  +10 -0 
ant/src/testcases/org/apache/tools/ant/taskdefs/ZipTest.java
  
  Index: ZipTest.java
  ===
  RCS file: 
/home/cvs/ant/src/testcases/org/apache/tools/ant/taskdefs/ZipTest.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- ZipTest.java  10 Feb 2003 14:14:45 -  1.12
  +++ ZipTest.java  27 Mar 2003 09:43:49 -  1.13
  @@ -57,6 +57,7 @@
   
   import java.io.File;
   import java.io.IOException;
  +import java.util.zip.ZipEntry;
   import java.util.zip.ZipFile;
   import java.util.Enumeration;
   
  @@ -133,5 +134,14 @@
   
   public void testUpdateIsNecessary() {
   expectLogContaining(testUpdateIsNecessary, Updating);
  +}
  +
  +// Bugzilla Report 18403
  +public void testPrefixAddsDir() throws IOException {
  +executeTarget(testPrefixAddsDir);
  +File archive = getProject().resolveFile(test3.zip);
  +ZipFile zf = new ZipFile(archive);
  +ZipEntry ze = zf.getEntry(test/);
  +assertNotNull(test/ has been added, ze);
   }
   }
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs Zip.java

2003-03-27 Thread bodewig
bodewig 2003/03/27 02:02:04

  Modified:.WHATSNEW
   src/main/org/apache/tools/ant/taskdefs Zip.java
  Log:
  prefix attribute of zipfileset would not generate directory entries
  for the prefix itself.
  
  PR: 18403
  
  Revision  ChangesPath
  1.373 +8 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.372
  retrieving revision 1.373
  diff -u -r1.372 -r1.373
  --- WHATSNEW  27 Mar 2003 08:24:21 -  1.372
  +++ WHATSNEW  27 Mar 2003 10:02:02 -  1.373
  @@ -211,6 +211,14 @@
   * Ant will no longer implicitly add Sun's rt.jar in javac when you
 use jvc and don't specify a bootclasspath.  Bugzilla Report 18055.
   
  +* The prefix attribute of zipfileset would not generate directory
  +  entries for the prefix itself.  Bugzilla Report 18403.
  +
  +Other Changes:
  +--
  +* Added ability to specify manifest encoding for the jar and 
  +  manifest tasks
  +
   Changes from Ant 1.5.1 to Ant 1.5.2
   =
   
  
  
  
  1.103 +5 -4  ant/src/main/org/apache/tools/ant/taskdefs/Zip.java
  
  Index: Zip.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Zip.java,v
  retrieving revision 1.102
  retrieving revision 1.103
  diff -u -r1.102 -r1.103
  --- Zip.java  18 Mar 2003 13:15:48 -  1.102
  +++ Zip.java  27 Mar 2003 10:02:04 -  1.103
  @@ -558,10 +558,11 @@
+  file.);
   }
   
  -if (prefix.length()  0
  - !prefix.endsWith(/)
  - !prefix.endsWith(\\)) {
  -prefix += /;
  +if (prefix.length()  0) {
  +if (!prefix.endsWith(/)  !prefix.endsWith(\\)) {
  +prefix += /;
  +}
  +addParentDirs(null, prefix, zOut, , dirMode);
   }
   
   ZipFile zf = null;
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs Zip.java

2003-03-27 Thread bodewig
bodewig 2003/03/27 02:07:20

  Modified:.Tag: ANT_15_BRANCH WHATSNEW
   src/main/org/apache/tools/ant/taskdefs Tag: ANT_15_BRANCH
Zip.java
  Log:
  Merge fix for 18403 from HEAD
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.263.2.129 +3 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.263.2.128
  retrieving revision 1.263.2.129
  diff -u -r1.263.2.128 -r1.263.2.129
  --- WHATSNEW  22 Mar 2003 10:23:50 -  1.263.2.128
  +++ WHATSNEW  27 Mar 2003 10:07:19 -  1.263.2.129
  @@ -30,6 +30,9 @@
   * Ant will no longer implicitly add Sun's rt.jar in javac when you
 use jvc and don't specify a bootclasspath.  Bugzilla Report 18055.
 
  +* The prefix attribute of zipfileset would not generate directory
  +  entries for the prefix itself.  Bugzilla Report 18403.
  +
   Other Changes:
   --
   * Added ability to specify manifest encoding for the jar and 
  
  
  
  No   revision
  
  
  No   revision
  
  
  1.78.2.15 +6 -5  ant/src/main/org/apache/tools/ant/taskdefs/Zip.java
  
  Index: Zip.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Zip.java,v
  retrieving revision 1.78.2.14
  retrieving revision 1.78.2.15
  diff -u -r1.78.2.14 -r1.78.2.15
  --- Zip.java  18 Mar 2003 13:13:34 -  1.78.2.14
  +++ Zip.java  27 Mar 2003 10:07:19 -  1.78.2.15
  @@ -93,7 +93,7 @@
*
* @author James Davidson a href=mailto:[EMAIL PROTECTED][EMAIL 
PROTECTED]/a
* @author Jon S. Stevens a href=mailto:[EMAIL PROTECTED][EMAIL 
PROTECTED]/a
  - * @author a href=mailto:[EMAIL PROTECTED]Stefan Bodewig/a
  + * @author Stefan Bodewig
* @author a href=mailto:[EMAIL PROTECTED]Antoine Levy-Lambert/a
*
* @since Ant 1.1
  @@ -537,10 +537,11 @@
+  file.);
   }
   
  -if (prefix.length()  0
  - !prefix.endsWith(/)
  - !prefix.endsWith(\\)) {
  -prefix += /;
  +if (prefix.length()  0) {
  +if (!prefix.endsWith(/)  !prefix.endsWith(\\)) {
  +prefix += /;
  +}
  +addParentDirs(null, prefix, zOut, , dirMode);
   }
   
   ZipFile zf = null;
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs ExecuteOn.java

2003-03-27 Thread bodewig
bodewig 2003/03/27 05:14:31

  Modified:.WHATSNEW
   docs/manual/CoreTasks apply.html
   src/main/org/apache/tools/ant/taskdefs ExecuteOn.java
  Log:
  Add a forwardslash attribute to apply
  
  Submitted by: Zdenek Wagner wagner at cesnet dot cz
  
  Revision  ChangesPath
  1.374 +5 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.373
  retrieving revision 1.374
  diff -u -r1.373 -r1.374
  --- WHATSNEW  27 Mar 2003 10:02:02 -  1.373
  +++ WHATSNEW  27 Mar 2003 13:14:31 -  1.374
  @@ -179,6 +179,11 @@
   
   * New task sync that synchronizes two directory trees.
   
  +* apply has new forwardslash attribute that can force filenames to
  +  use forward slashes (/) as file separators even on platforms with a
  +  different separator.  This is useful if you want to run certain
  +  ported Unix tools.
  +
   Changes from Ant 1.5.2 to Ant 1.5.3
   ===
   
  
  
  
  1.19  +9 -1  ant/docs/manual/CoreTasks/apply.html
  
  Index: apply.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/apply.html,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- apply.html26 Sep 2002 13:55:28 -  1.18
  +++ apply.html27 Mar 2003 13:14:31 -  1.19
  @@ -58,6 +58,14 @@
   td align=center valign=topNo, default is ifalse/i/td
 /tr
 tr
  +td valign=topforwardslash/td
  +td valign=topwhether the absolute file names should be passed
  +  with forward slashes even if the operating system requires other
  +  file separator. The option is ignored if the system file separator
  +  is a forward slash./td
  +td align=center valign=topNo, default is ifalse/i/td
  +  /tr
  +  tr
   td valign=topos/td
   td valign=toplist of Operating Systems on which the command may be
 executed./td
  @@ -220,7 +228,7 @@
   code.o/code, replacing TARGETFILE with the absolute filename of
   the code.o/code and SOURCEFILE with the absolute name of the
   code.c/code file./p
  -hrp align=centerCopyright copy; 2000-2002 Apache Software Foundation. 
All rights
  +hrp align=centerCopyright copy; 2000-2003 Apache Software Foundation. 
All rights
   Reserved./p
   
   /body
  
  
  
  1.38  +18 -1 ant/src/main/org/apache/tools/ant/taskdefs/ExecuteOn.java
  
  Index: ExecuteOn.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/ExecuteOn.java,v
  retrieving revision 1.37
  retrieving revision 1.38
  diff -u -r1.37 -r1.38
  --- ExecuteOn.java7 Mar 2003 11:23:01 -   1.37
  +++ ExecuteOn.java27 Mar 2003 13:14:31 -  1.38
  @@ -1,7 +1,7 @@
   /*
* The Apache Software License, Version 1.1
*
  - * Copyright (c) 2000-2002 The Apache Software Foundation.  All rights 
  + * Copyright (c) 2000-2003 The Apache Software Foundation.  All rights 
* reserved.
*
* Redistribution and use in source and binary forms, with or without
  @@ -83,6 +83,7 @@
   protected Vector filesets = new Vector();
   private boolean relative = false;
   private boolean parallel = false;
  +private boolean forwardSlash = false;
   protected String type = file;
   protected Commandline.Marker srcFilePos = null;
   private boolean skipEmpty = false;
  @@ -145,6 +146,14 @@
   }
   
   /**
  + * The source and target file names on Windows and OS/2 must use
  + * forward slash as file separator.
  + */
  +public void setForwardslash(boolean forwardSlash) {
  +this.forwardSlash = forwardSlash;
  +}
  +
  +/**
* Marker that indicates where the name of the source file should
* be put on the command line.
*/
  @@ -284,6 +293,7 @@
* @param baseDir filenames are relative to this dir
*/
   protected String[] getCommandline(String[] srcFiles, File[] baseDirs) {
  +final char fileSeparator = File.separatorChar;
   Vector targets = new Vector();
   if (targetFilePos != null) {
   Hashtable addedFiles = new Hashtable();
  @@ -297,6 +307,9 @@
   } else {
   name = subTargets[j];
   }
  +if (forwardSlash  fileSeparator != '/') {
  +name = name.replace(fileSeparator, '/');
  +}
   if (!addedFiles.contains(name)) {
   targets.addElement(name);
   addedFiles.put(name, name);
  @@ -379,6 +392,10 @@
   (new File(baseDirs[i], srcFiles[i])).getAbsolutePath();
   } else

cvs commit: ant/xdocs external.xml

2003-03-27 Thread bodewig
bodewig 2003/03/27 05:19:54

  Modified:docs Tag: ANT_15_BRANCH external.html
   xdocsTag: ANT_15_BRANCH external.xml
  Log:
  sync with HEAD
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.48.2.35 +3 -2  ant/docs/external.html
  
  Index: external.html
  ===
  RCS file: /home/cvs/ant/docs/external.html,v
  retrieving revision 1.48.2.34
  retrieving revision 1.48.2.35
  diff -u -r1.48.2.34 -r1.48.2.35
  --- external.html 25 Mar 2003 09:15:02 -  1.48.2.34
  +++ external.html 27 Mar 2003 13:19:53 -  1.48.2.35
  @@ -209,8 +209,9 @@
 table class=nowrap border=0 cellspacing=0 cellpadding=2 
width=100%
   trtd bgcolor=#294563font color=#ffa name=External Tools 
and TasksstrongExternal Tools and Tasks/strong/a/font/td/tr
 /table
  -pThis page lists external resources for Apache 
Ant: tasks, IDE
  -  integration tools, loggers, you name it. If you've written
  +pThis page lists external resources for Apache 
Ant: a href=#Taskstasks/a, a href=#Compiler%20ImplementationsCompiler 
Implementations/a,
  +  a href=#IDE%20and%20Editor%20IntegrationIDE integration
  +  tools/a, loggers, you name it. If you've written
 something that should be included, please post all relevant
 information to one of the mailing lists.  For details, see the
 a href=faq.html#adding-external-tasksFAQ/a./p
  
  
  
  No   revision
  
  
  No   revision
  
  
  1.35.2.34 +5 -2  ant/xdocs/external.xml
  
  Index: external.xml
  ===
  RCS file: /home/cvs/ant/xdocs/external.xml,v
  retrieving revision 1.35.2.33
  retrieving revision 1.35.2.34
  diff -u -r1.35.2.33 -r1.35.2.34
  --- external.xml  25 Mar 2003 09:15:04 -  1.35.2.33
  +++ external.xml  27 Mar 2003 13:19:54 -  1.35.2.34
  @@ -10,8 +10,11 @@
   
   section name=External Tools and Tasks
   
  -  pThis page lists external resources for Apache Ant: tasks, IDE
  -  integration tools, loggers, you name it. If you've written
  +  pThis page lists external resources for Apache Ant: a
  +  href=#Taskstasks/a, a
  +  href=#Compiler%20ImplementationsCompiler Implementations/a,
  +  a href=#IDE%20and%20Editor%20IntegrationIDE integration
  +  tools/a, loggers, you name it. If you've written
 something that should be included, please post all relevant
 information to one of the mailing lists.  For details, see the
 a href=faq.html#adding-external-tasksFAQ/a./p
  
  
  


cvs commit: ant/docs/manual/CoreTasks apply.html

2003-03-27 Thread bodewig
bodewig 2003/03/27 05:22:33

  Modified:docs/manual/CoreTasks apply.html
  Log:
  Not only the absolute paths
  
  Revision  ChangesPath
  1.20  +1 -1  ant/docs/manual/CoreTasks/apply.html
  
  Index: apply.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/apply.html,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -r1.19 -r1.20
  --- apply.html27 Mar 2003 13:14:31 -  1.19
  +++ apply.html27 Mar 2003 13:22:33 -  1.20
  @@ -59,7 +59,7 @@
 /tr
 tr
   td valign=topforwardslash/td
  -td valign=topwhether the absolute file names should be passed
  +td valign=topwhether the file names should be passed
 with forward slashes even if the operating system requires other
 file separator. The option is ignored if the system file separator
 is a forward slash./td
  
  
  


cvs commit: ant/proposal/xdocs/templates datatype_xdoc.template task_defaults_properties.template task_xdoc.template type_defaults_properties.template

2003-03-27 Thread bodewig
bodewig 2003/03/27 07:02:12

  Removed: proposal/mutant Tag: ANT_15_BRANCH .cvsignore bootstrap.bat
bootstrap.sh build.bat build.sh build.xml
   proposal/mutant/build Tag: ANT_15_BRANCH ant1compat.xml
bootstrap.xml bootstrap.xsl docs.xml script.xml
   proposal/mutant/docs Tag: ANT_15_BRANCH desc.html
   proposal/mutant/lib/ant1compat Tag: ANT_15_BRANCH readme.txt
   proposal/mutant/lib/antlib/script Tag: ANT_15_BRANCH
readme.txt
   proposal/mutant/src/java/antcore/org/apache/ant/antcore/antlib
Tag: ANT_15_BRANCH AntLibDefinition.java
AntLibHandler.java AntLibManager.java
AntLibrary.java AntLibrarySpec.java
ClassNameHandler.java ComponentLibrary.java
DefinitionHandler.java DynamicLibrary.java
   proposal/mutant/src/java/antcore/org/apache/ant/antcore/config
Tag: ANT_15_BRANCH AntConfig.java
AntConfigHandler.java
   proposal/mutant/src/java/antcore/org/apache/ant/antcore/execution
Tag: ANT_15_BRANCH AttributeSetter.java
BuildEventSupport.java ClassIntrospector.java
ComponentManager.java Constants.java
CoreDataService.java CoreEventService.java
CoreExecService.java CoreFileService.java
CoreInputService.java DeferredSetter.java
ExecutionContext.java ExecutionException.java
ExecutionManager.java Frame.java ImportInfo.java
Reflector.java Setter.java TaskAdapter.java
   
proposal/mutant/src/java/antcore/org/apache/ant/antcore/modelparser
Tag: ANT_15_BRANCH BuildElementHandler.java
IncludeHandler.java ModelElementHandler.java
NoProjectReadException.java ProjectHandler.java
TargetHandler.java XMLProjectParser.java
   proposal/mutant/src/java/antcore/org/apache/ant/antcore/xml
Tag: ANT_15_BRANCH ElementHandler.java
ParseContext.java RootHandler.java
XMLParseException.java
   proposal/mutant/src/java/antlibs/ant1compat Tag:
ANT_15_BRANCH antlib.xml
   proposal/mutant/src/java/antlibs/ant1compat/org/apache/tools/ant
Tag: ANT_15_BRANCH Ant1Converter.java
Ant1Factory.java Ant1InputHandler.java Project.java
ProjectComponent.java ProjectHelper.java
Target.java Task.java TaskContainer.java
   
proposal/mutant/src/java/antlibs/ant1compat/org/apache/tools/ant/input
Tag: ANT_15_BRANCH InputRequest.java
   
proposal/mutant/src/java/antlibs/ant1compat/org/apache/tools/ant/taskdefs
Tag: ANT_15_BRANCH Ant.java CallTarget.java
   
proposal/mutant/src/java/antlibs/ant1compat/org/apache/tools/ant/types
Tag: ANT_15_BRANCH DataType.java
   proposal/mutant/src/java/antlibs/script Tag: ANT_15_BRANCH
antlib.xml
   
proposal/mutant/src/java/antlibs/script/org/apache/ant/antlib/script
Tag: ANT_15_BRANCH ScriptBase.java ScriptDef.java
ScriptFactory.java
   proposal/mutant/src/java/antlibs/system Tag: ANT_15_BRANCH
antlib.xml
   
proposal/mutant/src/java/antlibs/system/org/apache/ant/antlib/system
Tag: ANT_15_BRANCH Ant.java AntBase.java
AntCall.java FileConverter.java Import.java
LibPath.java LoadLib.java Parallel.java
PrimitiveConverter.java Ref.java Sequential.java
SubBuild.java Taskdef.java Typedef.java
URLConverter.java
   proposal/mutant/src/java/bootstrap/org/apache/ant/bootstrap
Tag: ANT_15_BRANCH Bootstrap.java
   proposal/mutant/src/java/bootstrap/org/apache/ant/builder
Tag: ANT_15_BRANCH Ant1CompatBuilder.java
BuildHelper.java Builder.java MutantBuilder.java
   proposal/mutant/src/java/common/org/apache/ant/common/antlib
Tag: ANT_15_BRANCH AbstractComponent.java
AbstractConverter.java AbstractTask.java
AntContext.java AntLibFactory.java Converter.java
DataType.java DeferredTask.java
ExecutionComponent.java StandardLibFactory.java

cvs commit: ant/docs/manual/CoreTasks copy.html move.html

2003-03-27 Thread bodewig
bodewig 2003/03/27 07:51:22

  Modified:docs/manual/CoreTasks Tag: ANT_15_BRANCH copy.html move.html
  Log:
  Documentation of copy's encoding attribute is missing
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.10.2.7  +6 -0  ant/docs/manual/CoreTasks/copy.html
  
  Index: copy.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/copy.html,v
  retrieving revision 1.10.2.6
  retrieving revision 1.10.2.7
  diff -u -r1.10.2.6 -r1.10.2.7
  --- copy.html 19 Mar 2003 08:32:06 -  1.10.2.6
  +++ copy.html 27 Mar 2003 15:51:22 -  1.10.2.7
  @@ -103,6 +103,12 @@
td valign=topLog the files that are being copied./td
td valign=top align=centerNo; defaults to false./td
 /tr
  +  tr
  +td valign=topencoding/td
  +td valign=topThe encoding to assume when filter-copying the
  +files. emsince Ant 1.5/em./td
  +td align=centerNo - defaults to default JVM encoding/td
  +  /tr
   /table
   h3Parameters specified as nested elements/h3
   
  
  
  
  1.6.2.8   +6 -0  ant/docs/manual/CoreTasks/move.html
  
  Index: move.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/move.html,v
  retrieving revision 1.6.2.7
  retrieving revision 1.6.2.8
  diff -u -r1.6.2.7 -r1.6.2.8
  --- move.html 19 Mar 2003 08:33:10 -  1.6.2.7
  +++ move.html 27 Mar 2003 15:51:22 -  1.6.2.8
  @@ -89,6 +89,12 @@
td valign=topLog the files that are being moved./td
td valign=top align=centerNo; defaults to false./td
 /tr
  +  tr
  +td valign=topencoding/td
  +td valign=topThe encoding to assume when filter-moving the
  +files. emsince Ant 1.5/em./td
  +td align=centerNo - defaults to default JVM encoding/td
  +  /tr
   /table
   h3Parameters specified as nested elements/h3
   h4mapper/h4
  
  
  


cvs commit: ant/src/etc/testcases/taskdefs/copy - New directory

2003-03-27 Thread bodewig
bodewig 2003/03/27 07:57:51

  ant/src/etc/testcases/taskdefs/copy - New directory


cvs commit: ant/src/etc/testcases/taskdefs/copy/input - New directory

2003-03-27 Thread bodewig
bodewig 2003/03/27 07:58:03

  ant/src/etc/testcases/taskdefs/copy/input - New directory


cvs commit: ant/src/etc/testcases/taskdefs/copy/expected - New directory

2003-03-27 Thread bodewig
bodewig 2003/03/27 07:59:15

  ant/src/etc/testcases/taskdefs/copy/expected - New directory


cvs commit: ant/src/testcases/org/apache/tools/ant/taskdefs CopyTest.java

2003-03-27 Thread bodewig
bodewig 2003/03/27 08:32:19

  Modified:.WHATSNEW
   docs/manual/CoreTasks copy.html move.html
   src/etc/testcases/taskdefs copy.xml
   src/main/org/apache/tools/ant/taskdefs Copy.java Move.java
Sync.java
   src/main/org/apache/tools/ant/util FileUtils.java
   src/testcases/org/apache/tools/ant/taskdefs CopyTest.java
  Added:   src/etc/testcases/taskdefs/copy/expected utf-8
   src/etc/testcases/taskdefs/copy/input iso8859-1
  Log:
  Add outputencoding attribute to copy and friends.
  
  PR: 18217
  
  Revision  ChangesPath
  1.375 +3 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.374
  retrieving revision 1.375
  diff -u -r1.374 -r1.375
  --- WHATSNEW  27 Mar 2003 13:14:31 -  1.374
  +++ WHATSNEW  27 Mar 2003 16:32:18 -  1.375
  @@ -184,6 +184,9 @@
 different separator.  This is useful if you want to run certain
 ported Unix tools.
   
  +* Copy has a new outputencoding attribute that can be used to change
  +  the encoding while copying files.  Bugzilla Report 18217.
  +
   Changes from Ant 1.5.2 to Ant 1.5.3
   ===
   
  
  
  
  1.16  +13 -0 ant/docs/manual/CoreTasks/copy.html
  
  Index: copy.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/copy.html,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -r1.15 -r1.16
  --- copy.html 5 Feb 2003 15:32:26 -   1.15
  +++ copy.html 27 Mar 2003 16:32:18 -  1.16
  @@ -104,6 +104,19 @@
td valign=topLog the files that are being copied./td
td valign=top align=centerNo; defaults to false./td
 /tr
  +  tr
  +td valign=topencoding/td
  +td valign=topThe encoding to assume when filter-copying the
  +files. emsince Ant 1.5/em./td
  +td align=centerNo - defaults to default JVM encoding/td
  +  /tr
  +  tr
  +td valign=topoutputencoding/td
  +td valign=topThe encoding to use when writing the files.
  +emsince Ant 1.6/em./td
  +td align=centerNo - defaults to the value of the encoding
  +attribute if given or the default JVM encoding otherwise./td
  +  /tr
   /table
   h3Parameters specified as nested elements/h3
   
  
  
  
  1.11  +13 -0 ant/docs/manual/CoreTasks/move.html
  
  Index: move.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/move.html,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- move.html 19 Mar 2003 08:33:27 -  1.10
  +++ move.html 27 Mar 2003 16:32:18 -  1.11
  @@ -89,6 +89,19 @@
td valign=topLog the files that are being moved./td
td valign=top align=centerNo; defaults to false./td
 /tr
  +  tr
  +td valign=topencoding/td
  +td valign=topThe encoding to assume when filter-copying the
  +files. emsince Ant 1.5/em./td
  +td align=centerNo - defaults to default JVM encoding/td
  +  /tr
  +  tr
  +td valign=topoutputencoding/td
  +td valign=topThe encoding to use when writing the files.
  +emsince Ant 1.6/em./td
  +td align=centerNo - defaults to the value of the encoding
  +attribute if given or the default JVM encoding otherwise./td
  +  /tr
   /table
   h3Parameters specified as nested elements/h3
   h4mapper/h4
  
  
  
  1.9   +5 -0  ant/src/etc/testcases/taskdefs/copy.xml
  
  Index: copy.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/taskdefs/copy.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- copy.xml  6 Mar 2002 03:25:50 -   1.8
  +++ copy.xml  27 Mar 2003 16:32:18 -  1.9
  @@ -62,6 +62,11 @@
   /copy
 /target
   
  +  target name=testTranscoding
  +copy file=copy/input/iso8859-1 tofile=copytest1.tmp
  +  encoding=ISO8859_1 outputencoding=UTF8/
  +  /target
  +
 target name=cleanup 
   delete file=copytest1.tmp/
   delete file=copytest3.tmp/
  
  
  
  1.1  ant/src/etc/testcases/taskdefs/copy/expected/utf-8
  
Binary file
  
  
  1.1  ant/src/etc/testcases/taskdefs/copy/input/iso8859-1
  
Binary file
  
  
  1.53  +29 -6 ant/src/main/org/apache/tools/ant/taskdefs/Copy.java
  
  Index: Copy.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Copy.java,v
  retrieving revision 1.52
  retrieving revision 1.53
  diff -u -r1.52 -r1.53
  --- Copy.java 7 Mar 2003 11:23:00 -   1.52
  +++ Copy.java 27 Mar 2003 16:32:18 -  1.53
  @@ -118,7 +118,8 @@
   private Vector

cvs commit: ant/src/testcases/org/apache/tools/ant/filters StripJavaCommentsTest.java

2003-03-27 Thread bodewig
bodewig 2003/03/27 08:54:00

  Modified:src/etc/testcases/filters build.xml
  Added:   src/etc/testcases/filters/expected stripjavacomments.test
   src/etc/testcases/filters/input stripjavacomments.test
   src/testcases/org/apache/tools/ant/filters
StripJavaCommentsTest.java
  Log:
  demonstrate bug 17441
  
  Revision  ChangesPath
  1.3   +9 -0  ant/src/etc/testcases/filters/build.xml
  
  Index: build.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/filters/build.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- build.xml 14 Mar 2003 13:45:16 -  1.2
  +++ build.xml 27 Mar 2003 16:54:00 -  1.3
  @@ -39,4 +39,13 @@
   /fixcrlf
 /target
   
  +  target name=testStripJavaComments depends=init
  +copy todir=result
  +  fileset dir=input includes=stripjavacomments.test /
  +  filterchain
  +filterreader 
classname=org.apache.tools.ant.filters.StripJavaComments /
  +  /filterchain
  +/copy
  +  /target
  +
   /project
  
  
  
  1.1  
ant/src/etc/testcases/filters/expected/stripjavacomments.test
  
  Index: stripjavacomments.test
  ===
  
  
   
  public class NormalLine {
  
  private String withComment; 
  
  
  public void doNothing() {
  
  int i;
  
  int j;
  }
  
  private String url = http://ant.apache.org/;; 
  private String url2 = \http://ant.apache.org/\;;
  
  }
  
  
  
  1.1  
ant/src/etc/testcases/filters/input/stripjavacomments.test
  
  Index: stripjavacomments.test
  ===
  /*
   * Copyright text
   * has to be removed
   */
  
  /**
   * JavaDoc text about the class.
   * has to be removed
   */ 
  public class NormalLine {
  
  private String withComment; // this comment should be removed
  
  /* this comment
   * should be
   * removed
   */
  public void doNothing() {
  // this comment should be removed
  int i;
  /* this comment
 should be removed
  */
  int j;
  }
  
  private String url = http://ant.apache.org/;; // very difficult!
  private String url2 = \http://ant.apache.org/\;; // even worse
  
  }
  
  
  1.1  
ant/src/testcases/org/apache/tools/ant/filters/StripJavaCommentsTest.java
  
  Index: StripJavaCommentsTest.java
  ===
  /*
   * The Apache Software License, Version 1.1
   *
   * Copyright (c) 2003 The Apache Software Foundation.  All rights
   * reserved.
   *
   * Redistribution and use in source and binary forms, with or without
   * modification, are permitted provided that the following conditions
   * are met:
   *
   * 1. Redistributions of source code must retain the above copyright
   *notice, this list of conditions and the following disclaimer.
   *
   * 2. Redistributions in binary form must reproduce the above copyright
   *notice, this list of conditions and the following disclaimer in
   *the documentation and/or other materials provided with the
   *distribution.
   *
   * 3. The end-user documentation included with the redistribution, if
   *any, must include the following acknowlegement:
   *   This product includes software developed by the
   *Apache Software Foundation (http://www.apache.org/).
   *Alternately, this acknowlegement may appear in the software itself,
   *if and wherever such third-party acknowlegements normally appear.
   *
   * 4. The names Ant and Apache Software
   *Foundation must not be used to endorse or promote products derived
   *from this software without prior written permission. For written
   *permission, please contact [EMAIL PROTECTED]
   *
   * 5. Products derived from this software may not be called Apache
   *nor may Apache appear in their names without prior written
   *permission of the Apache Group.
   *
   * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
   * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
   * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
   * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
   * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
   * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
   * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
   * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
   * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
   * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
   * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED

cvs commit: ant/src/main/org/apache/tools/ant/filters StripJavaComments.java

2003-03-27 Thread bodewig
bodewig 2003/03/27 09:03:13

  Modified:src/etc/testcases/filters/expected stripjavacomments.test
   src/main/org/apache/tools/ant/filters StripJavaComments.java
  Log:
  stripjavacomments would consider // inside String constants comments.
  
  PR: 17441
  Submitted by: Jan Materne jan at materne dot de
  
  Revision  ChangesPath
  1.2   +1 -1  
ant/src/etc/testcases/filters/expected/stripjavacomments.test
  
  Index: stripjavacomments.test
  ===
  RCS file: 
/home/cvs/ant/src/etc/testcases/filters/expected/stripjavacomments.test,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- stripjavacomments.test27 Mar 2003 16:54:00 -  1.1
  +++ stripjavacomments.test27 Mar 2003 17:03:12 -  1.2
  @@ -14,6 +14,6 @@
   }
   
   private String url = http://ant.apache.org/;; 
  -private String url2 = \http://ant.apache.org/\;;
  +private String url2 = \http://ant.apache.org/\;; 
   
   }
  
  
  
  1.9   +11 -2 
ant/src/main/org/apache/tools/ant/filters/StripJavaComments.java
  
  Index: StripJavaComments.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/filters/StripJavaComments.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- StripJavaComments.java10 Feb 2003 14:13:32 -  1.8
  +++ StripJavaComments.java27 Mar 2003 17:03:13 -  1.9
  @@ -1,7 +1,7 @@
   /*
* The Apache Software License, Version 1.1
*
  - * Copyright (c) 2002 The Apache Software Foundation.  All rights
  + * Copyright (c) 2002-2003 The Apache Software Foundation.  All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
  @@ -80,6 +80,11 @@
*/
   private boolean inString = false;
   
  +/** 
  + * Whether or not the last char has been a backslash.
  + */
  +private boolean quoted = false;
  +
   /**
* Constructor for dummy instances.
* 
  @@ -116,9 +121,13 @@
   readAheadCh = -1;
   } else {
   ch = in.read();
  -if (ch == '') {
  +if (ch == ''  !quoted) {
   inString = !inString;
  +quoted = false;
  +} else if (ch == '\\') {
  +quoted = !quoted;
   } else {
  +quoted = false;
   if (!inString) {
   if (ch == '/') {
   ch = in.read();
  
  
  


cvs commit: ant/lib README xercesImpl.jar

2003-03-28 Thread bodewig
bodewig 2003/03/27 22:53:44

  Modified:.WHATSNEW
   lib  README xercesImpl.jar
  Log:
  Upgrade to Xerces 2.4.0
  
  Revision  ChangesPath
  1.376 +2 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.375
  retrieving revision 1.376
  diff -u -r1.375 -r1.376
  --- WHATSNEW  27 Mar 2003 16:32:18 -  1.375
  +++ WHATSNEW  28 Mar 2003 06:53:39 -  1.376
  @@ -77,6 +77,8 @@
   
   Other changes:
   --
  +* Shipped XML parser is now Xerces 2.4.0
  +
   * The filesetmanifest attribute of jar has been reenabled.
   
   * The start and end tokens for translate may now be longer than a
  
  
  
  1.15  +1 -1  ant/lib/README
  
  Index: README
  ===
  RCS file: /home/cvs/ant/lib/README,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- README28 Jan 2003 08:23:09 -  1.14
  +++ README28 Mar 2003 06:53:39 -  1.15
  @@ -2,7 +2,7 @@
   Dependencies for a list of the jar requirements for various optional
   tasks and features.
   
  -This directory contains xercesImpl.jar from the 2.3.0 release of
  +This directory contains xercesImpl.jar from the 2.4.0 release of
   Apache Xerces.  For more information or newer releases see
   http://xml.apache.org/xerces2-j/.  See the file LICENSE.xerces for
   the terms of distribution.
  
  
  
  1.7   +1875 -1777ant/lib/xercesImpl.jar
  
Binary file
  
  


cvs commit: ant/src/testcases/org/apache/tools/ant/taskdefs CopyTest.java

2003-03-28 Thread bodewig
bodewig 2003/03/27 23:33:05

  Modified:src/etc/testcases/taskdefs copy.xml
   src/testcases/org/apache/tools/ant/taskdefs CopyTest.java
  Log:
  Demonstrate bug 18414
  
  Revision  ChangesPath
  1.10  +22 -0 ant/src/etc/testcases/taskdefs/copy.xml
  
  Index: copy.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/taskdefs/copy.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- copy.xml  27 Mar 2003 16:32:18 -  1.9
  +++ copy.xml  28 Mar 2003 07:33:04 -  1.10
  @@ -67,6 +67,28 @@
 encoding=ISO8859_1 outputencoding=UTF8/
 /target
   
  +  target name=testMissingFileIgnore
  +copy file=not-there tofile=copytest1.tmp
  +  failonerror=false/
  +  /target
  +
  +  target name=testMissingFileBail
  +copy file=not-there tofile=copytest1.tmp
  +  failonerror=true/
  +  /target
  +
  +  target name=testMissingDirIgnore
  +copy todir=copytest1dir failonerror=false
  +  fileset dir=not-there/
  +/copy
  +  /target
  +
  +  target name=testMissingDirBail
  +copy todir=copytest1dir failonerror=false
  +  fileset dir=not-there/
  +/copy
  +  /target
  +
 target name=cleanup 
   delete file=copytest1.tmp/
   delete file=copytest3.tmp/
  
  
  
  1.12  +20 -0 
ant/src/testcases/org/apache/tools/ant/taskdefs/CopyTest.java
  
  Index: CopyTest.java
  ===
  RCS file: 
/home/cvs/ant/src/testcases/org/apache/tools/ant/taskdefs/CopyTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- CopyTest.java 27 Mar 2003 16:32:19 -  1.11
  +++ CopyTest.java 28 Mar 2003 07:33:05 -  1.12
  @@ -158,4 +158,24 @@
   File f2 = getProject().resolveFile(copytest1.tmp);
   assertTrue(fileUtils.contentEquals(f1, f2));
   }
  +
  +public void testMissingFileIgnore() {
  +expectLogContaining(testMissingFileIgnore, 
  +Warning: Could not find file );
  +}
  +
  +public void testMissingFileBail() {
  +expectBuildException(testMissingFileBail, not-there doesn't 
exist);
  +assertTrue(getBuildException().getMessage()
  +   .startsWith(Warning: Could not find file ));
  +}
  +
  +public void testMissingDirIgnore() {
  +expectLogContaining(testMissingDirIgnore, Warning: );
  +}
  +
  +public void testMissingDirBail() {
  +expectBuildException(testMissingDirBail, not-there doesn't 
exist);
  +assertTrue(getBuildException().getMessage().endsWith( not found.));
  +}
   }
  
  
  


cvs commit: ant/src/etc/testcases/taskdefs copy.xml

2003-03-28 Thread bodewig
bodewig 2003/03/27 23:35:31

  Modified:src/etc/testcases/taskdefs copy.xml
  Log:
  Oops
  
  Revision  ChangesPath
  1.11  +1 -1  ant/src/etc/testcases/taskdefs/copy.xml
  
  Index: copy.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/taskdefs/copy.xml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- copy.xml  28 Mar 2003 07:33:04 -  1.10
  +++ copy.xml  28 Mar 2003 07:35:31 -  1.11
  @@ -84,7 +84,7 @@
 /target
   
 target name=testMissingDirBail
  -copy todir=copytest1dir failonerror=false
  +copy todir=copytest1dir failonerror=true
 fileset dir=not-there/
   /copy
 /target
  
  
  


cvs commit: ant/src/testcases/org/apache/tools/ant TaskContainerTest.java

2003-03-28 Thread bodewig
bodewig 2003/03/28 00:41:15

  Added:   src/etc/testcases/core Tag: ANT_15_BRANCH taskcontainer.xml
   src/testcases/org/apache/tools/ant Tag: ANT_15_BRANCH
TaskContainerTest.java
  Log:
  Add testcase that shows property expansion in action for 1.5 - this one passes
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.1.2.1   +13 -0 ant/src/etc/testcases/core/Attic/taskcontainer.xml
  
  
  
  
  No   revision
  
  
  No   revision
  
  
  1.1.2.1   +74 -0 
ant/src/testcases/org/apache/tools/ant/Attic/TaskContainerTest.java
  
  
  
  


cvs commit: ant build.xml

2003-03-28 Thread bodewig
bodewig 2003/03/28 01:06:36

  Modified:.build.xml
  Log:
  Disable failing test
  
  Revision  ChangesPath
  1.357 +1 -0  ant/build.xml
  
  Index: build.xml
  ===
  RCS file: /home/cvs/ant/build.xml,v
  retrieving revision 1.356
  retrieving revision 1.357
  diff -u -r1.356 -r1.357
  --- build.xml 11 Mar 2003 14:42:42 -  1.356
  +++ build.xml 28 Mar 2003 09:06:36 -  1.357
  @@ -302,6 +302,7 @@
 patternset id=teststhatfail
   exclude name=${optional.package}/BeanShellScriptTest.java/
   exclude name=${ant.package}/taskdefs/ImportTest.java/
  +exclude name=${ant.package}/TaskContainerTest.java/
 /patternset
   
 !--
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/junit XMLJUnitResultFormatter.java

2003-03-28 Thread bodewig
bodewig 2003/03/28 04:20:51

  Modified:.WHATSNEW
   src/main/org/apache/tools/ant/taskdefs/optional/junit
XMLJUnitResultFormatter.java
  Log:
  The xml formatter for JUnit will now honor test case names set with
  setName
  
  PR: 17040
  
  Revision  ChangesPath
  1.379 +3 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.378
  retrieving revision 1.379
  diff -u -r1.378 -r1.379
  --- WHATSNEW  28 Mar 2003 08:28:15 -  1.378
  +++ WHATSNEW  28 Mar 2003 12:20:50 -  1.379
  @@ -195,6 +195,9 @@
   * Copy has a new outputencoding attribute that can be used to change
 the encoding while copying files.  Bugzilla Report 18217.
   
  +* The xml formatter for JUnit will now honor test case names set with
  +  setName.  Bugzilla Report 17040.
  +
   Changes from Ant 1.5.2 to Ant 1.5.3
   ===
   
  
  
  
  1.27  +18 -11
ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/XMLJUnitResultFormatter.java
  
  Index: XMLJUnitResultFormatter.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/XMLJUnitResultFormatter.java,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -r1.26 -r1.27
  --- XMLJUnitResultFormatter.java  7 Mar 2003 11:23:06 -   1.26
  +++ XMLJUnitResultFormatter.java  28 Mar 2003 12:20:51 -  1.27
  @@ -1,7 +1,7 @@
   /*
* The Apache Software License, Version 1.1
*
  - * Copyright (c) 2000-2002 The Apache Software Foundation.  All rights
  + * Copyright (c) 2000-2003 The Apache Software Foundation.  All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
  @@ -104,6 +104,10 @@
*/
   private Hashtable testElements = new Hashtable();
   /**
  + * tests that failed.
  + */
  +private Hashtable failedTests = new Hashtable();
  +/**
* Timing helper.
*/
   private Hashtable testStarts = new Hashtable();
  @@ -186,12 +190,6 @@
*/
   public void startTest(Test t) {
   testStarts.put(t, new Long(System.currentTimeMillis()));
  -
  -Element currentTest = doc.createElement(TESTCASE);
  -currentTest.setAttribute(ATTR_NAME, 
  - JUnitVersionHelper.getTestCaseName(t));
  -rootElement.appendChild(currentTest);
  -testElements.put(t, currentTest);
   }
   
   /**
  @@ -200,16 +198,24 @@
* pA Test is finished.
*/
   public void endTest(Test test) {
  -Element currentTest = (Element) testElements.get(test);
  -
   // Fix for bug #5637 - if a junit.extensions.TestSetup is
   // used and throws an exception during setUp then startTest
   // would never have been called
  -if (currentTest == null) {
  +if (!testStarts.containsKey(test)) {
   startTest(test);
  +}
  +
  +Element currentTest = null;
  +if (!failedTests.containsKey(test)) {
  +currentTest = doc.createElement(TESTCASE);
  +currentTest.setAttribute(ATTR_NAME, 
  + 
JUnitVersionHelper.getTestCaseName(test));
  +rootElement.appendChild(currentTest);
  +testElements.put(test, currentTest);
  +} else {
   currentTest = (Element) testElements.get(test);
   }
  -
  +
   Long l = (Long) testStarts.get(test);
   currentTest.setAttribute(ATTR_TIME,
+ ((System.currentTimeMillis() - l.longValue()) / 1000.0));
  @@ -245,6 +251,7 @@
   private void formatError(String type, Test test, Throwable t) {
   if (test != null) {
   endTest(test);
  +failedTests.put(test, test);
   }
   
   Element nested = doc.createElement(type);
  
  
  


cvs commit: ant/docs/manual/OptionalTasks pvcstask.html

2003-03-28 Thread bodewig
bodewig 2003/03/28 04:51:51

  Modified:docs/manual/OptionalTasks pvcstask.html
  Log:
  Improve pvcs docs by moving a paragraph
  
  Revision  ChangesPath
  1.7   +9 -5  ant/docs/manual/OptionalTasks/pvcstask.html
  
  Index: pvcstask.html
  ===
  RCS file: /home/cvs/ant/docs/manual/OptionalTasks/pvcstask.html,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- pvcstask.html 9 Jul 2002 21:05:52 -   1.6
  +++ pvcstask.html 28 Mar 2003 12:51:51 -  1.7
  @@ -9,6 +9,14 @@
   
   h1
   Ant Pvcs Task User Manual/h1
  +
  +pbNote:/b
  +Before using this task, the user running ant must have access to the
  +commands of PVCS (get and pcli) and must have access to the
  +repository. Note that the way to specify the repository is platform
  +dependent so use property to specify location of repository.
  +/p
  +
   by
   br!-- Names are in alphabetical order, on last name --
   ul
  @@ -34,10 +42,6 @@
   of the source code from a PVCS repository. PVCS is a version control system
   developed by a href=http://www.merant.com/products/pvcs;Merant/a.
   br
  -Before using this tag, the user running ant must have access to the commands
  -of PVCS (get and pcli) and must have access to the repository. Note that the 
way to specify
  -the repository is platform dependent so use property to specify location of 
repository.
  -br
   This version has been tested agains PVCS version 6.5 and 6.6 under Windows 
and Solaris.
   
   hr
  @@ -248,7 +252,7 @@
 Total time: 22 seconds/pre
   
   hr WIDTH=100%
  -p align=centerCopyright copy; 2001-2002 Apache Software
  +p align=centerCopyright copy; 2001-2003 Apache Software
   Foundation. All rights Reserved./p
   pPVCS is a registered trademark of MERANT./p
   /body
  
  
  


cvs commit: ant/docs/manual/OptionalTasks pvcstask.html

2003-03-28 Thread bodewig
bodewig 2003/03/28 04:54:18

  Modified:docs/manual/OptionalTasks Tag: ANT_15_BRANCH pvcstask.html
  Log:
  Improve pvcs docs by moving a paragraph
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.4.2.3   +9 -5  ant/docs/manual/OptionalTasks/pvcstask.html
  
  Index: pvcstask.html
  ===
  RCS file: /home/cvs/ant/docs/manual/OptionalTasks/pvcstask.html,v
  retrieving revision 1.4.2.2
  retrieving revision 1.4.2.3
  diff -u -r1.4.2.2 -r1.4.2.3
  --- pvcstask.html 4 Jul 2002 11:36:51 -   1.4.2.2
  +++ pvcstask.html 28 Mar 2003 12:54:18 -  1.4.2.3
  @@ -9,6 +9,14 @@
   
   h1
   Ant Pvcs Task User Manual/h1
  +
  +pbNote:/b
  +Before using this task, the user running ant must have access to the
  +commands of PVCS (get and pcli) and must have access to the
  +repository. Note that the way to specify the repository is platform
  +dependent so use property to specify location of repository.
  +/p
  +
   by
   br!-- Names are in alphabetical order, on last name --
   ul
  @@ -34,10 +42,6 @@
   of the source code from a PVCS repository. PVCS is a version control system
   developed by a href=http://www.merant.com/products/pvcs;Merant/a.
   br
  -Before using this tag, the user running ant must have access to the commands 
  -of PVCS (get and pcli) and must have access to the repository. Note that the 
way to specify
  -the repository is platform dependent so use property to specify location of 
repository.
  -br
   This version has been tested agains PVCS version 6.5 and 6.6 under Windows 
and Solaris.
   
   hr
  @@ -248,7 +252,7 @@
 Total time: 22 seconds/pre
   
   hr WIDTH=100%
  -p align=centerCopyright copy; 2001-2002 Apache Software
  +p align=centerCopyright copy; 2001-2003 Apache Software
   Foundation. All rights Reserved./p
   pPVCS is a registered trademark of MERANT./p
   /body
  
  
  


cvs commit: ant/docs/manual/CoreTasks mail.html

2003-03-28 Thread bodewig
bodewig 2003/03/28 07:02:53

  Modified:docs/manual/CoreTasks mail.html
  Log:
  files attribute splits at spaces as well.
  
  Revision  ChangesPath
  1.15  +2 -2  ant/docs/manual/CoreTasks/mail.html
  
  Index: mail.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/mail.html,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- mail.html 23 Sep 2002 16:14:00 -  1.14
  +++ mail.html 28 Mar 2003 15:02:53 -  1.15
  @@ -65,7 +65,7 @@
 tr
   td valign=topfiles/td
   td valign=topFiles to send as attachments to the email.  Separate 
multiple
  -file names using a comma.  You can also use codelt;filesetgt;/code
  +file names using a comma or space.  You can also use 
codelt;filesetgt;/code
   elements to specify files./td
   td align=center valign=topNo/td
 /tr
  @@ -188,7 +188,7 @@
   that order depending on what support classes are available. 
code${buildname}/code
   will be replaced with the codebuildname/code property's value./p
   hr
  -p align=centerCopyright copy; 2000-2002 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2000-2003 Apache Software Foundation. All 
rights
   Reserved./p
   
   /body
  
  
  


cvs commit: ant/docs/manual/CoreTasks mail.html

2003-03-28 Thread bodewig
bodewig 2003/03/28 07:05:11

  Modified:docs/manual/CoreTasks Tag: ANT_15_BRANCH mail.html
  Log:
  files attribute splits at spaces as well.
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.10.2.7  +2 -2  ant/docs/manual/CoreTasks/mail.html
  
  Index: mail.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/mail.html,v
  retrieving revision 1.10.2.6
  retrieving revision 1.10.2.7
  diff -u -r1.10.2.6 -r1.10.2.7
  --- mail.html 23 Sep 2002 16:15:48 -  1.10.2.6
  +++ mail.html 28 Mar 2003 15:05:11 -  1.10.2.7
  @@ -65,7 +65,7 @@
 tr
   td valign=topfiles/td
   td valign=topFiles to send as attachments to the email.  Separate 
multiple
  -file names using a comma.  You can also use codelt;filesetgt;/code
  +file names using a comma or space.  You can also use 
codelt;filesetgt;/code
   elements to specify files./td
   td align=center valign=topNo/td
 /tr
  @@ -188,7 +188,7 @@
   that order depending on what support classes are available. 
code${buildname}/code
   will be replaced with the codebuildname/code property's value./p
   hr
  -p align=centerCopyright copy; 2000-2002 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2000-2003 Apache Software Foundation. All 
rights
   Reserved./p
   
   /body
  
  
  


cvs commit: ant/src/script ant

2003-03-31 Thread bodewig
bodewig 2003/03/31 01:22:25

  Modified:.Tag: ANT_15_BRANCH WHATSNEW
   src/main/org/apache/tools/ant/taskdefs/optional/starteam
Tag: ANT_15_BRANCH TreeBasedTask.java
   src/script Tag: ANT_15_BRANCH ant
  Log:
  Merge fixes for 17646 and 17721 from HEAD
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.263.2.130 +5 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.263.2.129
  retrieving revision 1.263.2.130
  diff -u -r1.263.2.129 -r1.263.2.130
  --- WHATSNEW  27 Mar 2003 10:07:19 -  1.263.2.129
  +++ WHATSNEW  31 Mar 2003 09:22:24 -  1.263.2.130
  @@ -33,6 +33,11 @@
   * The prefix attribute of zipfileset would not generate directory
 entries for the prefix itself.  Bugzilla Report 18403.
   
  +* starteam checkout can now handle deleted labels.  Bugzilla Report 17646.
  +
  +* The Unix wrapper script failed if you invoked it as a relative
  +  symlink and ANT_HOME has not been set.  Bugzilla Report 17721.
  +
   Other Changes:
   --
   * Added ability to specify manifest encoding for the jar and 
  
  
  
  No   revision
  
  
  No   revision
  
  
  1.8.2.4   +1 -1  
ant/src/main/org/apache/tools/ant/taskdefs/optional/starteam/TreeBasedTask.java
  
  Index: TreeBasedTask.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/starteam/TreeBasedTask.java,v
  retrieving revision 1.8.2.3
  retrieving revision 1.8.2.4
  diff -u -r1.8.2.3 -r1.8.2.4
  --- TreeBasedTask.java13 Feb 2003 13:59:53 -  1.8.2.3
  +++ TreeBasedTask.java31 Mar 2003 09:22:25 -  1.8.2.4
  @@ -566,7 +566,7 @@
   for (int i = 0; i  allLabels.length; i++) {
   Label stLabel = allLabels[i];
   log(checking label  + stLabel.getName(), Project.MSG_DEBUG);
  -if (stLabel.getName().equals(this.label)) {
  +if (stLabel != null  !stLabel.isDeleted()  
stLabel.getName().equals(this.label)) {
   if (!stLabel.isRevisionLabel()  !stLabel.isViewLabel()) {
   throw new BuildException(Unexpected label type.);
   }
  
  
  
  No   revision
  
  
  No   revision
  
  
  1.19.2.15 +4 -4  ant/src/script/ant
  
  Index: ant
  ===
  RCS file: /home/cvs/ant/src/script/ant,v
  retrieving revision 1.19.2.14
  retrieving revision 1.19.2.15
  diff -u -r1.19.2.14 -r1.19.2.15
  --- ant   21 Feb 2003 11:54:51 -  1.19.2.14
  +++ ant   31 Mar 2003 09:22:25 -  1.19.2.15
  @@ -55,7 +55,7 @@
 while [ -h $PRG ] ; do
   ls=`ls -ld $PRG`
   link=`expr $ls : '.*- \(.*\)$'`
  -if expr $link : '.*/.*'  /dev/null; then
  +if expr $link : '/.*'  /dev/null; then
PRG=$link
   else
PRG=`dirname $PRG`/$link
  @@ -150,9 +150,9 @@
   
 # OSX hack to make Ant work with jikes
 if $darwin ; then
  -
OSXHACK=/System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Classes
  -if [ -d ${OSXHACK} ] ; then
  -  for i in ${OSXHACK}/*.jar
  +OSXHACK=${JAVA_HOME}/../Classes
  +if [ -d ${OSXHACK} ] ; then
  +  for i in ${OSXHACK}/*.jar
 do
   JIKESPATH=$JIKESPATH:$i
 done
  
  
  


cvs commit: ant WHATSNEW

2003-03-31 Thread bodewig
bodewig 2003/03/31 01:23:57

  Modified:.WHATSNEW
  Log:
  Two fixes will be in 1.5.3
  
  Revision  ChangesPath
  1.381 +5 -5  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.380
  retrieving revision 1.381
  diff -u -r1.380 -r1.381
  --- WHATSNEW  28 Mar 2003 12:41:00 -  1.380
  +++ WHATSNEW  31 Mar 2003 09:23:57 -  1.381
  @@ -70,11 +70,6 @@
 StringIndexOutOfBoundsException on all OSes where os.name is shorter
 than seven characters.  Bugzilla Report 18105.
   
  -* starteam checkout can now handle deleted labels.  Bugzilla Report 17646.
  -
  -* The Unix wrapper script failed if you invoked it as a relative
  -  symlink and ANT_HOME has not been set.  Bugzilla Report 17721.
  -
   * copy and move's failonerror didn't apply to filesets pointing to
 non-existant directories.  Bugzilla Report 18414.
   
  @@ -235,6 +230,11 @@
   
   * The prefix attribute of zipfileset would not generate directory
 entries for the prefix itself.  Bugzilla Report 18403.
  +
  +* starteam checkout can now handle deleted labels.  Bugzilla Report 17646.
  +
  +* The Unix wrapper script failed if you invoked it as a relative
  +  symlink and ANT_HOME has not been set.  Bugzilla Report 17721.
   
   Other Changes:
   --
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/junit JUnitTask.java

2003-03-31 Thread bodewig
bodewig 2003/03/31 04:27:14

  Modified:.WHATSNEW
   docs/manual/OptionalTasks junit.html
   src/main/org/apache/tools/ant/taskdefs/optional/junit
JUnitTask.java
  Log:
  Add tempdir attribute to junit to control placement of temporary file.
  
  PR: 15454
  
  Revision  ChangesPath
  1.382 +3 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.381
  retrieving revision 1.382
  diff -u -r1.381 -r1.382
  --- WHATSNEW  31 Mar 2003 09:23:57 -  1.381
  +++ WHATSNEW  31 Mar 2003 12:27:13 -  1.382
  @@ -196,6 +196,9 @@
   * concat now supports filtering and can check timestamps before
 overriding a file.  Bugzilla Report 18166.
   
  +* junit has a new attribute tempdir that controls the placement of
  +  temporary files.  Bugzilla Report 15454.
  +
   Changes from Ant 1.5.2 to Ant 1.5.3
   ===
   
  
  
  
  1.24  +8 -1  ant/docs/manual/OptionalTasks/junit.html
  
  Index: junit.html
  ===
  RCS file: /home/cvs/ant/docs/manual/OptionalTasks/junit.html,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -r1.23 -r1.24
  --- junit.html6 Sep 2002 06:16:39 -   1.23
  +++ junit.html31 Mar 2003 12:27:13 -  1.24
  @@ -142,6 +142,13 @@
 formatters receive the output./td
   td align=center valign=topNo/td
 /tr
  +  tr
  +td valign=toptempdir/td
  +td valign=topWhere Ant should place temporary files.
  +  emSince Ant 1.6/em./td
  +td align=center valign=topNo; default is the project's base
  +  directory./td
  +  /tr
   /table
   
   pBy using the codeerrorproperty/code and codefailureproperty/code
  @@ -479,7 +486,7 @@
   code${reports.tests}/code./p
   
   hr
  -p align=centerCopyright copy; 2000-2002 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2000-2003 Apache Software Foundation. All 
rights
   Reserved./p
   /body
   /html
  
  
  
  1.59  +12 -1 
ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/JUnitTask.java
  
  Index: JUnitTask.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/JUnitTask.java,v
  retrieving revision 1.58
  retrieving revision 1.59
  diff -u -r1.58 -r1.59
  --- JUnitTask.java7 Mar 2003 11:23:06 -   1.58
  +++ JUnitTask.java31 Mar 2003 12:27:14 -  1.59
  @@ -174,6 +174,7 @@
   private Path antRuntimeClasses = null;
   
   private boolean showOutput = false;
  +private File tmpDir;
   
   /**
* If true, smartly filter the stack frames of
  @@ -502,6 +503,15 @@
   }
   
   /**
  + * Where Ant should place temporary files.
  + *
  + * @since Ant 1.6
  + */
  +public void setTempdir(File tmpDir) {
  +this.tmpDir = tmpDir;
  +}
  +
  +/**
* Adds the jars or directories containing Ant, this task and
* JUnit to the classpath - this should make the forked JVM work
* without having to specify them directly.
  @@ -636,6 +646,7 @@
   // forked test
   File propsFile =
   FileUtils.newFileUtils().createTempFile(junit, .properties,
  +tmpDir != null ? tmpDir :
   
getProject().getBaseDir());
   cmd.createArgument().setValue(propsfile=
 + propsFile.getAbsolutePath());
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant Location.java

2003-03-31 Thread bodewig
bodewig 2003/03/31 07:08:37

  Modified:src/main/org/apache/tools/ant Location.java
  Log:
  unURIfy build-file name if necessary.
  
  PR: 18352
  
  Revision  ChangesPath
  1.12  +7 -2  ant/src/main/org/apache/tools/ant/Location.java
  
  Index: Location.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/Location.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- Location.java 10 Feb 2003 14:13:30 -  1.11
  +++ Location.java 31 Mar 2003 15:08:37 -  1.12
  @@ -1,7 +1,7 @@
   /*
* The Apache Software License, Version 1.1
*
  - * Copyright (c) 2000,2002 The Apache Software Foundation.  All rights
  + * Copyright (c) 2000,2002-2003 The Apache Software Foundation.  All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
  @@ -55,6 +55,7 @@
   package org.apache.tools.ant;
   
   import java.io.Serializable;
  +import org.apache.tools.ant.util.FileUtils;
   import org.xml.sax.Locator;
   
   /**
  @@ -118,7 +119,11 @@
* @param columnNumber Column number within the line.
*/
   public Location(String fileName, int lineNumber, int columnNumber) {
  -this.fileName = fileName;
  +if (fileName != null  fileName.startsWith(file:)) {
  +this.fileName = FileUtils.newFileUtils().fromURI(fileName);
  +} else {
  +this.fileName = fileName;
  +}
   this.lineNumber = lineNumber;
   this.columnNumber = columnNumber;
   }
  
  
  


cvs commit: ant/proposal/sandbox/antlib/src/main/org/apache/tools/ant IntrospectionHelper.java Project.java

2003-04-01 Thread bodewig
bodewig 2003/04/01 03:35:07

  Modified:proposal/sandbox/antlib/src/main/org/apache/tools/ant
IntrospectionHelper.java Project.java
  Log:
  Sync with main code line
  
  Revision  ChangesPath
  1.4   +451 -182  
ant/proposal/sandbox/antlib/src/main/org/apache/tools/ant/IntrospectionHelper.java
  
  Index: IntrospectionHelper.java
  ===
  RCS file: 
/home/cvs/ant/proposal/sandbox/antlib/src/main/org/apache/tools/ant/IntrospectionHelper.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- IntrospectionHelper.java  7 Mar 2003 11:22:58 -   1.3
  +++ IntrospectionHelper.java  1 Apr 2003 11:35:06 -   1.4
  @@ -1,7 +1,7 @@
   /*
* The Apache Software License, Version 1.1
*
  - * Copyright (c) 2000-2001 The Apache Software Foundation.  All rights
  + * Copyright (c) 2000-2003 The Apache Software Foundation.  All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
  @@ -23,7 +23,7 @@
*Alternately, this acknowlegement may appear in the software itself,
*if and wherever such third-party acknowlegements normally appear.
*
  - * 4. The names The Jakarta Project, Ant, and Apache Software
  + * 4. The names Ant and Apache Software
*Foundation must not be used to endorse or promote products derived
*from this software without prior written permission. For written
*permission, please contact [EMAIL PROTECTED]
  @@ -54,16 +54,15 @@
   
   package org.apache.tools.ant;
   
  -import org.apache.tools.ant.types.Path;
  -import org.apache.tools.ant.types.EnumeratedAttribute;
  -
  -import java.lang.reflect.Method;
  -import java.lang.reflect.InvocationTargetException;
  -import java.lang.reflect.Constructor;
   import java.io.File;
  +import java.lang.reflect.Constructor;
  +import java.lang.reflect.InvocationTargetException;
  +import java.lang.reflect.Method;
   import java.util.Enumeration;
   import java.util.Hashtable;
   import java.util.Locale;
  +import org.apache.tools.ant.types.EnumeratedAttribute;
  +import org.apache.tools.ant.types.Path;
   
   /**
* Helper class that collects the methods a task or nested element
  @@ -75,45 +74,125 @@
   public class IntrospectionHelper implements BuildListener {
   
   /**
  - * holds the types of the attributes that could be set.
  + * Map from attribute names to attribute types 
  + * (String to Class).
*/
   private Hashtable attributeTypes;
   
   /**
  - * holds the attribute setter methods.
  + * Map from attribute names to attribute setter methods 
  + * (String to AttributeSetter).
*/
   private Hashtable attributeSetters;
   
   /**
  - * Holds the types of nested elements that could be created.
  + * Map from attribute names to nested types 
  + * (String to Class).
*/
   private Hashtable nestedTypes;
   
   /**
  - * Holds methods to create nested elements.
  + * Map from attribute names to methods to create nested types 
  + * (String to NestedCreator).
*/
   private Hashtable nestedCreators;
   
   /**
  - * Holds methods to store configured nested elements.
  + * Map from attribute names to methods to store configured nested types 
  + * (String to NestedStorer).
*/
   private Hashtable nestedStorers;
   
   /**
  - * The method to add PCDATA stuff.
  + * The method to invoke to add PCDATA.
*/
   private Method addText = null;
   
   /**
  - * The Class that's been introspected.
  + * The class introspected by this instance.
*/
   private Class bean;
   
   /**
  - * instances we've already created
  + * Helper instances we've already created (Class to IntrospectionHelper).
*/
   private static Hashtable helpers = new Hashtable();
   
  +/** 
  + * Map from primitive types to wrapper classes for use in 
  + * createAttributeSetter (Class to Class). Note that char 
  + * and boolean are in here even though they get special treatment
  + * - this way we only need to test for the wrapper class.
  + */
  +private static final Hashtable PRIMITIVE_TYPE_MAP = new Hashtable(8);
  +
  +// Set up PRIMITIVE_TYPE_MAP
  +static {
  +Class[] primitives = {Boolean.TYPE, Byte.TYPE, Character.TYPE, 
  +  Short.TYPE, Integer.TYPE, Long.TYPE, 
  +  Float.TYPE, Double.TYPE};
  +Class[] wrappers = {Boolean.class, Byte.class, Character.class, 
  +Short.class, Integer.class, Long.class, 
  +Float.class, Double.class};
  +for (int i = 0; i  primitives.length; i++) {
  +PRIMITIVE_TYPE_MAP.put (primitives[i], wrappers[i

cvs commit: ant/proposal/sandbox/antlib/src/main/org/apache/tools/ant/taskdefs Antjar.java Antlib.java

2003-04-01 Thread bodewig
bodewig 2003/04/01 03:38:30

  Modified:proposal/sandbox/antlib/src/main/org/apache/tools/ant/taskdefs
Antjar.java Antlib.java
  Log:
  Part 2 of Antoine's patch
  
  Revision  ChangesPath
  1.5   +6 -8  
ant/proposal/sandbox/antlib/src/main/org/apache/tools/ant/taskdefs/Antjar.java
  
  Index: Antjar.java
  ===
  RCS file: 
/home/cvs/ant/proposal/sandbox/antlib/src/main/org/apache/tools/ant/taskdefs/Antjar.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- Antjar.java   7 Mar 2003 11:22:59 -   1.4
  +++ Antjar.java   1 Apr 2003 11:38:30 -   1.5
  @@ -1,7 +1,7 @@
   /*
*  The Apache Software License, Version 1.1
*
  - *  Copyright (c) 2000 The Apache Software Foundation.  All rights
  + *  Copyright (c) 2000,2003 The Apache Software Foundation.  All rights
*  reserved.
*
*  Redistribution and use in source and binary forms, with or without
  @@ -53,15 +53,12 @@
*/
   package org.apache.tools.ant.taskdefs;
   
  -import org.xml.sax.*;
  -import javax.xml.parsers.*;
   
   import org.apache.tools.ant.*;
   import org.apache.tools.ant.types.ZipFileSet;
   import org.apache.tools.zip.*;
   
   import java.io.*;
  -import java.util.*;
   
   /**
* Creates a ANTLIB archive. Code is similar to the War class, but with
  @@ -129,7 +126,7 @@
   // If no antxml file is specified, it's an error.
   if (libraryDescriptor == null) {
   throw new BuildException(antxml attribute is required, 
  -  location);
  +  getLocation());
   }
   
   super.initZipOutputStream(zOut);
  @@ -142,9 +139,10 @@
* @param file file to add
* @param zOut stream to add to 
* @param vPath the path to add it to in the zipfile
  + * @param mode the Unix permissions to set.
* @exception IOException io trouble
*/
  -protected void zipFile(File file, ZipOutputStream zOut, String vPath)
  +protected void zipFile(File file, ZipOutputStream zOut, String vPath, 
int mode)
   throws IOException {
   // If the file being added is META-INF/antlib.xml, we warn if it's 
not the
   // one specified in the antxml attribute - or if it's being added 
twice,
  @@ -159,12 +157,12 @@
 task), Project.MSG_WARN);
   }
   else {
  -super.zipFile(file, zOut, vPath);
  +super.zipFile(file, zOut, vPath, mode);
   descriptorAdded = true;
   }
   }
   else {
  -super.zipFile(file, zOut, vPath);
  +super.zipFile(file, zOut, vPath, mode);
   }
   }
   
  
  
  
  1.6   +25 -31
ant/proposal/sandbox/antlib/src/main/org/apache/tools/ant/taskdefs/Antlib.java
  
  Index: Antlib.java
  ===
  RCS file: 
/home/cvs/ant/proposal/sandbox/antlib/src/main/org/apache/tools/ant/taskdefs/Antlib.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- Antlib.java   3 Mar 2002 12:37:41 -   1.5
  +++ Antlib.java   1 Apr 2003 11:38:30 -   1.6
  @@ -1,7 +1,7 @@
   /*
*  The Apache Software License, Version 1.1
*
  - *  Copyright (c) 1999 The Apache Software Foundation.  All rights
  + *  Copyright (c) 1999,2003 The Apache Software Foundation.  All rights
*  reserved.
*
*  Redistribution and use in source and binary forms, with or without
  @@ -55,7 +55,6 @@
   
   import org.apache.tools.ant.*;
   import org.apache.tools.ant.types.*;
  -import org.apache.tools.ant.taskdefs.*;
   import org.xml.sax.*;
   import javax.xml.parsers.*;
   
  @@ -108,10 +107,6 @@
*/
   private Path classpath = null;
   
  -/**
  - * the manufacture set of classes to load
  - */
  -private Path loaderPath = null;
   
   /**
* our little xml parse
  @@ -357,7 +352,7 @@
* Default is codetrue/code.
* This property is mostly used by the core when loading core tasks.
*
  - * @param failedonerror if true loading will stop if classes
  + * @param onerror if true loading will stop if classes
*  cannot be instantiated
*/
   public void setOnerror(FailureAction onerror) {
  @@ -399,7 +394,7 @@
*/
   public Path createClasspath() {
   if (classpath == null) {
  -classpath = new Path(project);
  +classpath = new Path(getProject());
   }
   return classpath.createPath();
   }
  @@ -424,7 +419,7 @@
   private File libraryFile(String homeSubDir, String lib) {
   // For the time being libraries live in $ANT_HOME/antlib.
   // The idea being that not to load all the jars

cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh SSHExec.java

2003-04-01 Thread bodewig
bodewig 2003/04/01 05:01:09

  Modified:docs/manual/OptionalTasks scp.html sshexec.html
   src/main/org/apache/tools/ant/taskdefs/optional/ssh
SSHExec.java
  Log:
  Make sshexec wait for the remote command to finish.
  
  Requires jsch-0.1.3 to work.
  
  Submitted by: Dale Anson danson at germane dash software dot com
  
  Revision  ChangesPath
  1.6   +1 -1  ant/docs/manual/OptionalTasks/scp.html
  
  Index: scp.html
  ===
  RCS file: /home/cvs/ant/docs/manual/OptionalTasks/scp.html,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- scp.html  14 Mar 2003 15:10:26 -  1.5
  +++ scp.html  1 Apr 2003 13:01:09 -   1.6
  @@ -19,7 +19,7 @@
   pbNote:/b This task depends on external libraries not included
   in the Ant distribution.  See a
   href=../install.html#librarydependenciesLibrary Dependencies/a
  -for more information.  This task has been tested with jsch-0.1.2./p
  +for more information.  This task has been tested with jsch-0.1.2 and 
jsch-0.1.3./p
   
   h3Parameters/h3
   table border=1 cellpadding=2 cellspacing=0
  
  
  
  1.3   +23 -1 ant/docs/manual/OptionalTasks/sshexec.html
  
  Index: sshexec.html
  ===
  RCS file: /home/cvs/ant/docs/manual/OptionalTasks/sshexec.html,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- sshexec.html  14 Mar 2003 15:10:27 -  1.2
  +++ sshexec.html  1 Apr 2003 13:01:09 -   1.3
  @@ -18,7 +18,7 @@
   pbNote:/b This task depends on external libraries not included
   in the Ant distribution.  See a
   href=../install.html#librarydependenciesLibrary Dependencies/a
  -for more information.  This task has been tested with jsch-0.1.2./p
  +for more information.  This task has been tested with jsch-0.1.3./p
   
   h3Parameters/h3
   table border=1 cellpadding=2 cellspacing=0
  @@ -79,6 +79,28 @@
   td valign=toppassphrase/td
td valign=topPassphrase for your private key./td
td valign=top align=centerNo, defaults to an empty string./td
  +  /tr
  +  tr
  +td valign=topoutput/td
  +td valign=topName of a file to which to write the output./td
  +td align=center valign=topNo/td
  +  /tr
  +  tr
  +td valign=topappend/td
  +td valign=topWhether output file should be appended to or 
overwritten. Defaults to false, meaning overwrite any existing file./td
  +td align=center valign=topNo/td
  +  /tr
  +  tr
  +td valign=topoutputproperty/td
  +td valign=topThe name of a property in which the output of the 
  +  command should be stored./td
  +td align=center valign=topNo/td
  +  /tr
  +  tr
  +td valign=toptimeout/td
  +td valign=topStop the command if it doesn't finish within the
  +  specified time (given in seconds). Defaults to 0 which means 
quot;wait foreverquot;./td
  +td align=center valign=topNo/td
 /tr
   /table
   
  
  
  
  1.2   +195 -25   
ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/SSHExec.java
  
  Index: SSHExec.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/SSHExec.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- SSHExec.java  11 Mar 2003 13:15:43 -  1.1
  +++ SSHExec.java  1 Apr 2003 13:01:09 -   1.2
  @@ -56,14 +56,13 @@
   
   import org.apache.tools.ant.BuildException;
   import org.apache.tools.ant.Project;
  -import org.apache.tools.ant.Task;
  -import org.apache.tools.ant.TaskContainer;
  -import org.apache.tools.ant.taskdefs.LogOutputStream;
  -
  -import java.io.BufferedReader;
  -import java.io.InputStreamReader;
  -import java.util.Vector;
  -import java.util.Enumeration;
  +
  +import java.io.ByteArrayOutputStream;
  +import java.io.File;
  +import java.io.FileWriter;
  +import java.io.IOException;
  +import java.io.OutputStream;
  +import java.io.StringReader;
   
   import com.jcraft.jsch.Channel;
   import com.jcraft.jsch.ChannelExec;
  @@ -71,14 +70,22 @@
   
   /**
* Executes a command on a remote machine via ssh.
  + *
* @authorRobert Anderson, [EMAIL PROTECTED]
  + * @authorDale Anson, [EMAIL PROTECTED]
  + * @version   $Revision$
* @created   February 2, 2003
  - * @since Ant 1.6
  + * @since Ant 1.6
*/
   public class SSHExec extends SSHBase {
   
  -private String command = null;
  -private int maxwait = 3;
  +private String command = null;   // the command to execute via ssh
  +private int maxwait = 0;   // units are milliseconds, default is 
0=infinite
  +private Thread thread = null;   // for waiting for the command to finish
  +
  +private String output_property = null;   // like exec
  +private File output_file = null;   // like

cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh SSHExec.java

2003-04-01 Thread bodewig
bodewig 2003/04/01 05:09:28

  Modified:src/main/org/apache/tools/ant/taskdefs/optional/ssh
SSHExec.java
  Log:
  Compile, then commit!
  
  Revision  ChangesPath
  1.4   +1 -1  
ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/SSHExec.java
  
  Index: SSHExec.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/SSHExec.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- SSHExec.java  1 Apr 2003 13:05:25 -   1.3
  +++ SSHExec.java  1 Apr 2003 13:09:28 -   1.4
  @@ -170,7 +170,7 @@
   try {
   // execute the command
   Session session = openSession();
  -session.setTimeout(maxwait);
  +session.setTimeout((int) maxwait);
   final ChannelExec channel=(ChannelExec) 
session.openChannel(exec);
   channel.setCommand(command);
   channel.setOutputStream(tee);
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh SSHExec.java

2003-04-01 Thread bodewig
bodewig 2003/04/01 05:29:03

  Modified:src/main/org/apache/tools/ant/taskdefs/optional/junit
JUnitTestRunner.java
   src/main/org/apache/tools/ant/taskdefs/optional/ssh
SSHExec.java
  Log:
  Remove redundant classes
  
  Revision  ChangesPath
  1.34  +4 -29 
ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/JUnitTestRunner.java
  
  Index: JUnitTestRunner.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/JUnitTestRunner.java,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -r1.33 -r1.34
  --- JUnitTestRunner.java  7 Mar 2003 11:23:06 -   1.33
  +++ JUnitTestRunner.java  1 Apr 2003 13:29:01 -   1.34
  @@ -78,6 +78,7 @@
   import org.apache.tools.ant.BuildException;
   import org.apache.tools.ant.Project;
   import org.apache.tools.ant.util.StringUtils;
  +import org.apache.tools.ant.util.TeeOutputStream;
   
   /**
* Simple Testrunner for JUnit that runs all tests of a testsuite.
  @@ -302,17 +303,12 @@
   System.setErr(systemError);
   } else {
   System.setOut(new PrintStream(
  -  new TeeOutputStream(
  -  new OutputStream[] {savedOut, 
  -  systemOut}
  -  )
  +  new TeeOutputStream(savedOut, 
systemOut)
 )
 );
   System.setErr(new PrintStream(
  -  new TeeOutputStream(
  -  new OutputStream[] {savedErr, 
  -  systemError}
  -  )
  +  new TeeOutputStream(savedErr, 
  +  systemError)
 )
 );
   }
  @@ -613,25 +609,4 @@
   return false;
   }
   
  -/**
  - * Helper class that sends output sent to multiple streams.
  - *
  - * @since Ant 1.5
  - */
  -private class TeeOutputStream extends OutputStream {
  -
  -private OutputStream[] outs;
  -
  -private TeeOutputStream(OutputStream[] outs) {
  -this.outs = outs;
  -}
  -
  -public void write(int b) throws IOException {
  -for (int i = 0; i   outs.length; i++) {
  -outs[i].write(b);
  -}
  -}
  -
  -}
  -
   } // JUnitTestRunner
  
  
  
  1.5   +2 -62 
ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/SSHExec.java
  
  Index: SSHExec.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/ssh/SSHExec.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- SSHExec.java  1 Apr 2003 13:09:28 -   1.4
  +++ SSHExec.java  1 Apr 2003 13:29:03 -   1.5
  @@ -56,6 +56,7 @@
   
   import org.apache.tools.ant.BuildException;
   import org.apache.tools.ant.Project;
  +import org.apache.tools.ant.util.TeeOutputStream;
   
   import java.io.ByteArrayOutputStream;
   import java.io.File;
  @@ -165,7 +166,7 @@
   }
   
   ByteArrayOutputStream out = new ByteArrayOutputStream();
  -Tee tee = new Tee(out, System.out);
  +TeeOutputStream tee = new TeeOutputStream(out, System.out);
   
   try {
   // execute the command
  @@ -249,67 +250,6 @@
   if (out != null) {
   out.close();
   }
  -}
  -}
  -
  -/**
  - * Similar to standard unix tee utility, sends output to two streams.
  - *
  - * @authorDale Anson, [EMAIL PROTECTED]
  - * @version   $Revision$
  - */
  -public class Tee extends OutputStream {
  -
  -private OutputStream left = null;
  -private OutputStream right = null;
  -
  -/**
  - * Constructor for Tee, sends output to both of the given
  - * streams, which are referred to as the teed streams.
  - *
  - * @param left   one stream to write to
  - * @param right  the other stream to write to
  - */
  -public Tee(OutputStream left, OutputStream right) {
  -if (left == null || right == null) {
  -throw new IllegalArgumentException(Both streams are 
required.);
  -}
  -this.left = left;
  -this.right = right

cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional ANTLR.java

2003-04-01 Thread bodewig
bodewig 2003/04/01 05:47:06

  Modified:src/main/org/apache/tools/ant/taskdefs/optional ANTLR.java
  Log:
  Fix ANTLR's test8 testcase.
  
  Revision  ChangesPath
  1.21  +26 -3 
ant/src/main/org/apache/tools/ant/taskdefs/optional/ANTLR.java
  
  Index: ANTLR.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/ANTLR.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -r1.20 -r1.21
  --- ANTLR.java31 Mar 2003 13:46:18 -  1.20
  +++ ANTLR.java1 Apr 2003 13:47:06 -   1.21
  @@ -55,6 +55,7 @@
   package org.apache.tools.ant.taskdefs.optional;
   
   import java.io.BufferedReader;
  +import java.io.ByteArrayOutputStream;
   import java.io.File;
   import java.io.FileReader;
   import java.io.IOException;
  @@ -63,12 +64,14 @@
   import org.apache.tools.ant.Project;
   import org.apache.tools.ant.Task;
   import org.apache.tools.ant.taskdefs.Execute;
  -import org.apache.tools.ant.taskdefs.LogStreamHandler;
  +import org.apache.tools.ant.taskdefs.LogOutputStream;
  +import org.apache.tools.ant.taskdefs.PumpStreamHandler;
   import org.apache.tools.ant.types.Commandline;
   import org.apache.tools.ant.types.CommandlineJava;
   import org.apache.tools.ant.types.Path;
   import org.apache.tools.ant.util.JavaEnvUtils;
   import org.apache.tools.ant.util.LoaderUtils;
  +import org.apache.tools.ant.util.TeeOutputStream;
   
   /**
*  Invokes the ANTLR Translator generator on a grammar file.
  @@ -111,6 +114,9 @@
   /** working directory */
   private File workingdir = null;
   
  +/** captures ANTLR's output */
  +private ByteArrayOutputStream bos = new ByteArrayOutputStream();
  +
   public ANTLR() {
   commandline.setVm(JavaEnvUtils.getJreExecutable(java));
   commandline.setClassname(antlr.Tool);
  @@ -277,6 +283,12 @@
   int err = run(commandline.getCommandline());
   if (err == 1) {
   throw new BuildException(ANTLR returned:  + err, 
getLocation());
  +} else {
  +String output = bos.toString();
  +if (output.indexOf(error:)  -1) {
  +throw new BuildException(ANTLR signaled an error: 
  + + output, getLocation());
  +}
   }
   } else {
   log(Skipped grammar file. Generated file is newer., 
Project.MSG_VERBOSE);
  @@ -352,8 +364,14 @@
   
   /** execute in a forked VM */
   private int run(String[] command) throws BuildException {
  -Execute exe = new Execute(new LogStreamHandler(this, 
Project.MSG_INFO,
  -Project.MSG_WARN), null);
  +PumpStreamHandler psh = 
  +new PumpStreamHandler(new LogOutputStream(this, 
Project.MSG_INFO),
  +  new TeeOutputStream(
  +  new LogOutputStream(this, 
  +  Project.MSG_WARN),
  +  bos)
  +  );
  +Execute exe = new Execute(psh, null);
   exe.setAntRun(getProject());
   if (workingdir != null) {
   exe.setWorkingDirectory(workingdir);
  @@ -363,6 +381,11 @@
   return exe.execute();
   } catch (IOException e) {
   throw new BuildException(e, getLocation());
  +} finally {
  +try {
  +bos.close();
  +} catch (IOException e) {
  +}
   }
   }
   }
  
  
  


cvs commit: ant/src/testcases/org/apache/tools/ant/taskdefs/optional ANTLRTest.java

2003-04-01 Thread bodewig
bodewig 2003/04/01 06:33:29

  Modified:src/etc/testcases/taskdefs/optional/antlr antlr.xml
   src/main/org/apache/tools/ant/taskdefs/optional ANTLR.java
   src/testcases/org/apache/tools/ant/taskdefs/optional
ANTLRTest.java
  Log:
  demonstrate bug 12961
  
  Revision  ChangesPath
  1.9   +19 -0 ant/src/etc/testcases/taskdefs/optional/antlr/antlr.xml
  
  Index: antlr.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/taskdefs/optional/antlr/antlr.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- antlr.xml 1 Apr 2003 10:54:36 -   1.8
  +++ antlr.xml 1 Apr 2003 14:33:28 -   1.9
  @@ -73,6 +73,25 @@
   antlr target=antlr.g outputdirectory=${tmp.dir} traceLexer=yes 
traceParser=yes traceTreeWalker=yes/
 /target
   
  +  !-- test9 will have been run before that --
  +  target name=noRecompile
  +antlr target=${tmp.dir}/extended.calc.g glib=${tmp.dir}/antlr.g/
  +  /target
  +
  +  !-- test9 will have been run before that --
  +  target name=normalRecompile
  +sleep seconds=2/
  +touch file=${tmp.dir}/extended.calc.g/
  +antlr target=${tmp.dir}/extended.calc.g glib=${tmp.dir}/antlr.g/
  +  /target
  +
  +  !-- test9 will have been run before that --
  +  target name=supergrammarChangeRecompile
  +sleep seconds=2/
  +touch file=${tmp.dir}/antlr.g/
  +antlr target=${tmp.dir}/extended.calc.g glib=${tmp.dir}/antlr.g/
  +  /target
  +
 target name=cleanup
   delete dir=${tmp.dir} /
   delete file=../../../../../../CalcParserTokenTypes.txt/
  
  
  
  1.22  +7 -2  
ant/src/main/org/apache/tools/ant/taskdefs/optional/ANTLR.java
  
  Index: ANTLR.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/ANTLR.java,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -r1.21 -r1.22
  --- ANTLR.java1 Apr 2003 13:47:06 -   1.21
  +++ ANTLR.java1 Apr 2003 14:33:28 -   1.22
  @@ -275,7 +275,11 @@
   public void execute() throws BuildException {
   validateAttributes();
   //TODO: use ANTLR to parse the grammer file to do this.
  -if (target.lastModified()  getGeneratedFile().lastModified()) {
  +File generatedFile = getGeneratedFile();
  +if (target.lastModified()  generatedFile.lastModified()) {
  +log(Compiling  + target +  as it is newer than  
  ++ generatedFile, Project.MSG_VERBOSE);
  +
   populateAttributes();
   commandline.createArgument().setValue(target.toString());
   
  @@ -291,7 +295,8 @@
   }
   }
   } else {
  -log(Skipped grammar file. Generated file is newer., 
Project.MSG_VERBOSE);
  +log(Skipped grammar file. Generated file  + generatedFile 
  ++ is newer., Project.MSG_VERBOSE);
   }
   }
   
  
  
  
  1.13  +22 -0 
ant/src/testcases/org/apache/tools/ant/taskdefs/optional/ANTLRTest.java
  
  Index: ANTLRTest.java
  ===
  RCS file: 
/home/cvs/ant/src/testcases/org/apache/tools/ant/taskdefs/optional/ANTLRTest.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- ANTLRTest.java1 Apr 2003 10:54:36 -   1.12
  +++ ANTLRTest.java1 Apr 2003 14:33:28 -   1.13
  @@ -169,6 +169,28 @@
   public void test13() {
   executeTarget(test13);
   }
  +
  +public void testNoRecompile() {
  +executeTarget(test9);
  +assertEquals(-1, getFullLog().indexOf(Skipped grammar file.));
  +executeTarget(noRecompile);
  +assertTrue(-1 != getFullLog().indexOf(Skipped grammar file.));
  +}
  +
  +public void testNormalRecompile() {
  +executeTarget(test9);
  +assertEquals(-1, getFullLog().indexOf(Skipped grammar file.));
  +executeTarget(normalRecompile);
  +assertEquals(-1, getFullLog().indexOf(Skipped grammar file.));
  +}
  +
  +// Bugzilla Report 12961
  +public void testSupergrammarChangeRecompile() {
  +executeTarget(test9);
  +assertEquals(-1, getFullLog().indexOf(Skipped grammar file.));
  +executeTarget(supergrammarChangeRecompile);
  +assertEquals(-1, getFullLog().indexOf(Skipped grammar file.));
  +}
   }
   
   class CalcFileFilter implements FilenameFilter {
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional ANTLR.java

2003-04-01 Thread bodewig
bodewig 2003/04/01 06:44:00

  Modified:.WHATSNEW
   docs/manual/OptionalTasks antlr.html
   src/main/org/apache/tools/ant/taskdefs/optional ANTLR.java
  Log:
  Recompile grammar if supergrammar has changed.
  
  PR: 12961
  
  Revision  ChangesPath
  1.383 +3 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.382
  retrieving revision 1.383
  diff -u -r1.382 -r1.383
  --- WHATSNEW  31 Mar 2003 12:27:13 -  1.382
  +++ WHATSNEW  1 Apr 2003 14:44:00 -   1.383
  @@ -76,6 +76,9 @@
   * The stripjavacomments filter sometimes removed parts of string
 constants.  Bugzilla Report 17441.
   
  +* antlr will now recompile your grammar if the supergrammar has
  +  changed.  Bugzilla Report 12691.
  +
   Other changes:
   --
   * Shipped XML parser is now Xerces 2.4.0
  
  
  
  1.11  +12 -4 ant/docs/manual/OptionalTasks/antlr.html
  
  Index: antlr.html
  ===
  RCS file: /home/cvs/ant/docs/manual/OptionalTasks/antlr.html,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- antlr.html4 Sep 2002 11:05:18 -   1.10
  +++ antlr.html1 Apr 2003 14:44:00 -   1.11
  @@ -21,10 +21,11 @@
 the grammar file.
   /p
   p
  -  This task only invokes ANTLR if the grammar file is newer than the 
generated
  -  files.
  +  This task only invokes ANTLR if the grammar file (or the
  +  supergrammar specified by the glib attribute) is newer than the
  +  generated files.
   /p
  -p
  +pAntlr 2.7.1 Note:
   i
 To successfully run ANTLR, your best option is probably to build the whole
 jar with the provided script bmkalljar/b and drop the resulting jar 
(about 300KB)
  @@ -33,6 +34,13 @@
 to your classpath as described in ANTLR ttinstall.html/tt document.
   /i
   /p
  +pAntlr 2.7.2 Note:
  +i
  +  Instead of the above, you will need antlrall.jar that can be created
  +  by the bantlr-all.jar/b target of the Makefile provided with the
  +  download.
  +/i
  +/p
   
   h3Parameters/h3
   table border=1 cellpadding=2 cellspacing=0
  @@ -170,7 +178,7 @@
   /p
   hr
   
  -p align=centerCopyright copy; 2000-2002 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2000-2003 Apache Software Foundation. All 
rights
   Reserved./p
   
   /body
  
  
  
  1.23  +12 -4 
ant/src/main/org/apache/tools/ant/taskdefs/optional/ANTLR.java
  
  Index: ANTLR.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/ANTLR.java,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -r1.22 -r1.23
  --- ANTLR.java1 Apr 2003 14:33:28 -   1.22
  +++ ANTLR.java1 Apr 2003 14:44:00 -   1.23
  @@ -276,10 +276,18 @@
   validateAttributes();
   //TODO: use ANTLR to parse the grammer file to do this.
   File generatedFile = getGeneratedFile();
  -if (target.lastModified()  generatedFile.lastModified()) {
  -log(Compiling  + target +  as it is newer than  
  -+ generatedFile, Project.MSG_VERBOSE);
  -
  +boolean targetIsOutOfDate = 
  +target.lastModified()  generatedFile.lastModified();
  +boolean superGrammarIsOutOfDate = superGrammar != null 
  +(new File(superGrammar).lastModified()  
generatedFile.lastModified());
  +if (targetIsOutOfDate || superGrammarIsOutOfDate) {
  +if (targetIsOutOfDate) {
  +log(Compiling  + target +  as it is newer than  
  ++ generatedFile, Project.MSG_VERBOSE);
  +} else if (superGrammarIsOutOfDate) {
  +log(Compiling  + target +  as  + superGrammar
  ++  is newer than  + generatedFile, 
Project.MSG_VERBOSE);
  +}
   populateAttributes();
   commandline.createArgument().setValue(target.toString());
   
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/jdepend JDependTask.java

2003-04-02 Thread bodewig
bodewig 2003/04/02 04:00:27

  Modified:.WHATSNEW
   docs/manual/OptionalTasks jdepend.html
   src/main/org/apache/tools/ant/taskdefs/optional/jdepend
JDependTask.java
  Log:
  Add classespath nested element to mirror sourcespath but point to
  compiled classes.
  
  Add exclude nested element to conditionally exclude packages from
  being parsed.
  
  PR: 17134
  Submitted by: Bob Hays electricbob at alephnaught dot com
  
  Revision  ChangesPath
  1.384 +6 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.383
  retrieving revision 1.384
  diff -u -r1.383 -r1.384
  --- WHATSNEW  1 Apr 2003 14:44:00 -   1.383
  +++ WHATSNEW  2 Apr 2003 12:00:27 -   1.384
  @@ -202,6 +202,12 @@
   * junit has a new attribute tempdir that controls the placement of
 temporary files.  Bugzilla Report 15454.
   
  +* jdepend now supports a new nested element classespath which is
  +  the same as sourcespath but point to compiled classes (the
  +  prefered mode of operation for JDepend  2.5).  Additionally, nested
  +  exclude elements can be used to exclude certain packages from
  +  being parsed.  Bugzilla Report 17134.
  +
   Changes from Ant 1.5.2 to Ant 1.5.3
   ===
   
  
  
  
  1.9   +44 -15ant/docs/manual/OptionalTasks/jdepend.html
  
  Index: jdepend.html
  ===
  RCS file: /home/cvs/ant/docs/manual/OptionalTasks/jdepend.html,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- jdepend.html  4 Sep 2002 11:05:18 -   1.8
  +++ jdepend.html  2 Apr 2003 12:00:27 -   1.9
  @@ -19,14 +19,15 @@
   It allows to quot;automatically measure the quality of a design in terms of 
its extensibility, reusability, and maintainability to
   effectively manage and control package dependencies.quot;/P
   
  -pSource file directories are defined by nested 
codelt;sourcespathgt;/code, see a href=#nestednested elements/a./p
  +pSource file directories are defined by nested
  +codelt;sourcespathgt;/code; Class file directories are defined
  +by nested codelt;classesespathgt;/code, see a
  +href=#nestednested elements/a./p
   
   pOptionally, you can also set the codeoutputfile/code name where the 
output is stored. By default the task writes its report to the standard 
output./P
   
   p The task requires at least the JDepend 1.2 version. /p
   
  -PNote: whereas the JDepend tool can be customized to exclude some 
packages, the current jdepend And Task does not have parameters to allow these 
exclusions. Read JDepend specific documentation for that purpose./P
  -
   h3Parameters/h3
   
   table BORDER=1 CELLSPACING=0 CELLPADDING=2 
  @@ -79,26 +80,37 @@
   
   h3a name=nestedNested Elements/a/h3
   
  -pcodejdepend/code supports two nested elements 
codelt;classpathgt;/code and codelt;sourcespathgt;/code,
  -that represent a href=../using.html#pathPATH like structures/a./p
  -
  -pcodelt;sourcespathgt;/code is used to define the paths of the 
source code to analyze./p
  +pcodejdepend/code supports four nested elements:
  +codelt;classpathgt;, lt;classespathgt; /code and
  +codelt;sourcespathgt;/code, that represent a
  +href=../using.html#pathPATH like structures/a, and
  +codelt;excludegt;/code./p
  +
  +pcodelt;sourcespathgt;/code is used to define the paths of the
  +source code to analyze, but it is deprecated. With version 2.5 of
  +JDepend, only class files are analyzed. The nested element
  +lt;classespathgt; replaces lt;sourcespathgt; and is used to define
  +the paths of compiled class code to analyze; the lt;sourcespathgt;
  +variable is still available in case you are using an earlier version
  +of JDepend.  The lt;excludegt; element can be used to set packages
  +to ignore./p
   
   h3Examples/h3
   
   blockquote
   pre
   lt;jdepend classpathref=base.pathgt;
  -nbsp;nbsp;nbsp; lt;sourcespathgt;
  -nbsp;nbsp;nbsp; nbsp;nbsp;nbsp; lt;pathelement location=src/gt;
  -nbsp;nbsp;nbsp; lt;/sourcespathgt;
  +nbsp;nbsp;nbsp; lt;classespathgt;
  +nbsp;nbsp;nbsp; nbsp;nbsp;nbsp; lt;pathelement location=build/gt;
  +nbsp;nbsp;nbsp; lt;/classespathgt;
   lt;/jdependgt;
   
   /pre
   /blockquote
   
  -This invokes JDepend on the codesrc/code directory, writing the output 
on the standard output.
  -The classpath is defined using a classpath reference.
  +pThis invokes JDepend on the codebuild/code directory, writing
  +the output on the standard output. The classpath is defined using a
  +classpath reference./p
   
   blockquote
   pre
  @@ -111,15 +123,32 @@
   nbsp;nbsp;nbsp; nbsp;nbsp;nbsp; lt;pathelement 
location=lib/jdepend.jar/gt;
   nbsp;nbsp;nbsp; lt;/classpathgt;
   lt;/jdependgt;
  +/pre
  +/blockquote
  +
  +pThis invokes JDepend in a separate VM on the codesrc

cvs commit: ant/docs/manual/OptionalTasks antlr.html

2003-04-02 Thread bodewig
bodewig 2003/04/02 06:26:43

  Modified:docs/manual/OptionalTasks Tag: ANT_15_BRANCH antlr.html
  Log:
  Improve antlr docs
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.6.2.5   +9 -2  ant/docs/manual/OptionalTasks/antlr.html
  
  Index: antlr.html
  ===
  RCS file: /home/cvs/ant/docs/manual/OptionalTasks/antlr.html,v
  retrieving revision 1.6.2.4
  retrieving revision 1.6.2.5
  diff -u -r1.6.2.4 -r1.6.2.5
  --- antlr.html4 Sep 2002 11:21:14 -   1.6.2.4
  +++ antlr.html2 Apr 2003 14:26:43 -   1.6.2.5
  @@ -24,7 +24,7 @@
 This task only invokes ANTLR if the grammar file is newer than the 
generated
 files.
   /p
  -p
  +pAntlr 2.7.1 Note:
   i
 To successfully run ANTLR, your best option is probably to build the whole
 jar with the provided script bmkalljar/b and drop the resulting jar 
(about 300KB)
  @@ -33,6 +33,13 @@
 to your classpath as described in ANTLR ttinstall.html/tt document.
   /i
   /p
  +pAntlr 2.7.2 Note:
  +i
  +  Instead of the above, you will need antlrall.jar that can be created
  +  by the bantlr-all.jar/b target of the Makefile provided with the
  +  download.
  +/i
  +/p
   
   h3Parameters/h3
   table border=1 cellpadding=2 cellspacing=0
  @@ -170,7 +177,7 @@
   /p
   hr
   
  -p align=centerCopyright copy; 2000-2002 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2000-2003 Apache Software Foundation. All 
rights
   Reserved./p
   
   /body
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs Execute.java

2003-04-02 Thread bodewig
bodewig 2003/04/02 06:53:23

  Modified:.WHATSNEW
   src/main/org/apache/tools/ant/taskdefs Execute.java
  Log:
  Don't hardcode /usr/bin/env for Unix.
  
  PR: 17642
  
  Revision  ChangesPath
  1.385 +4 -1  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.384
  retrieving revision 1.385
  diff -u -r1.384 -r1.385
  --- WHATSNEW  2 Apr 2003 12:00:27 -   1.384
  +++ WHATSNEW  2 Apr 2003 14:53:20 -   1.385
  @@ -79,6 +79,9 @@
   * antlr will now recompile your grammar if the supergrammar has
 changed.  Bugzilla Report 12691.
   
  +* property env will now work on Unices with /bin/env instead of
  +  /usr/bin/env.  Bugzilla Report 17642.
  +
   Other changes:
   --
   * Shipped XML parser is now Xerces 2.4.0
  @@ -145,7 +148,7 @@
   * tarfileset has a new dirmode attribute to specify the permissions
 for directories.
   
  -* fixcrlf's eol attribute now also understand mac, unix and dos.
  +* fixcrlf's eol attribute now also understands mac, unix and dos.
   
   * classfileset now picks up dependencies of the form MyClass.class. This
 works for the code generated by the Sun java compiler. It may not work for
  
  
  
  1.53  +16 -12ant/src/main/org/apache/tools/ant/taskdefs/Execute.java
  
  Index: Execute.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Execute.java,v
  retrieving revision 1.52
  retrieving revision 1.53
  diff -u -r1.52 -r1.53
  --- Execute.java  14 Mar 2003 16:01:03 -  1.52
  +++ Execute.java  2 Apr 2003 14:53:22 -   1.53
  @@ -229,19 +229,23 @@
   String[] cmd = {command.com, /c, set };
   return cmd;
   }
  -} else if (Os.isFamily(z/os)) {
  -String[] cmd = {/bin/env};
  -return cmd;
  -} else if (Os.isFamily(tandem)) {
  -//String[] cmd = {/bin/sh -c env};
  -String[] cmd = {/bin/env};
  -return cmd;
  -} else if (Os.isFamily(unix)) {
  -// Generic UNIX
  -// Alternatively one could use: /bin/sh -c env
  -String[] cmd = {/usr/bin/env};
  +} else if (Os.isFamily(z/os) || Os.isFamily(tandem) 
  +   || Os.isFamily(unix)) {
  +// On most systems one could use: /bin/sh -c env
  +
  +// Some systems have /bin/env, others /usr/bin/env, just try
  +String[] cmd = new String[1];
  +if (new File(/bin/env).canRead()) {
  +cmd[0] = /bin/env;
  +} else if (new File(/usr/bin/env).canRead()) {
  +cmd[0] = /usr/bin/env;
  +} else {
  +// rely on PATH
  +cmd[0] = env;
  +}
   return cmd;
   } else if (Os.isFamily(netware) || Os.isFamily(os/400)) {
  +// rely on PATH
   String[] cmd = {env};
   return cmd;
   } else {
  
  
  


cvs commit: ant/src/testcases/org/apache/tools/ant/taskdefs JarTest.java

2003-04-02 Thread bodewig
bodewig 2003/04/02 07:53:38

  Modified:src/etc/testcases/taskdefs jar.xml
   src/testcases/org/apache/tools/ant/taskdefs JarTest.java
  Log:
  Demonstrate bug 10262
  
  Revision  ChangesPath
  1.11  +8 -0  ant/src/etc/testcases/taskdefs/jar.xml
  
  Index: jar.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/taskdefs/jar.xml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- jar.xml   12 Mar 2003 10:19:59 -  1.10
  +++ jar.xml   2 Apr 2003 15:53:37 -   1.11
  @@ -200,4 +200,12 @@
   mkdir dir=${tmp.dir}/
   unzip src=${tmp.jar} dest=${tmp.dir}/
 /target
  +
  +  !-- bug 10262 --
  +  target name=testNoDuplicateIndex
  +mkdir dir=${tmp.dir}/META-INF/
  +touch file=${tmp.dir}/META-INF/INDEX.LIST/
  +touch file=${tmp.dir}/foo/
  +jar destfile=${tmp.jar} index=yes basedir=${tmp.dir}/
  +  /target
   /project
  
  
  
  1.20  +17 -0 
ant/src/testcases/org/apache/tools/ant/taskdefs/JarTest.java
  
  Index: JarTest.java
  ===
  RCS file: 
/home/cvs/ant/src/testcases/org/apache/tools/ant/taskdefs/JarTest.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -r1.19 -r1.20
  --- JarTest.java  12 Mar 2003 10:19:59 -  1.19
  +++ JarTest.java  2 Apr 2003 15:53:38 -   1.20
  @@ -59,6 +59,9 @@
   import java.io.IOException;
   import java.io.Reader;
   import java.util.Date;
  +import java.util.Enumeration;
  +import java.util.zip.ZipEntry;
  +import java.util.zip.ZipFile;
   import org.apache.tools.ant.BuildFileTest;
   
   /**
  @@ -225,5 +228,19 @@
   executeTarget(testUpdateIfOnlyManifestHasChanged);
   File jarXml = getProject().resolveFile(tempDir + jar.xml);
   assertTrue(jarXml.exists());
  +}
  +
  +public void testNoDuplicateIndex() throws IOException {
  +executeTarget(testNoDuplicateIndex);
  +ZipFile archive = new ZipFile(getProject().resolveFile(tempJar));
  +Enumeration enum = archive.entries();
  +int numberOfIndexLists = 0;
  +while (enum.hasMoreElements()) {
  +ZipEntry ze = (ZipEntry) enum.nextElement();
  +if (ze.getName().equals(META-INF/INDEX.LIST)) {
  +numberOfIndexLists++;
  +}
  +}
  +assertEquals(1, numberOfIndexLists);
   }
   }
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs Jar.java

2003-04-02 Thread bodewig
bodewig 2003/04/02 08:01:15

  Modified:.WHATSNEW
   src/main/org/apache/tools/ant/taskdefs Jar.java
  Log:
  Ignore index lists found when creating a jar with index=on.
  
  PR: 10262
  
  Revision  ChangesPath
  1.386 +2 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.385
  retrieving revision 1.386
  diff -u -r1.385 -r1.386
  --- WHATSNEW  2 Apr 2003 14:53:20 -   1.385
  +++ WHATSNEW  2 Apr 2003 16:01:15 -   1.386
  @@ -82,6 +82,8 @@
   * property env will now work on Unices with /bin/env instead of
 /usr/bin/env.  Bugzilla Report 17642.
   
  +* jar index=on could include multiple index lists.  Bugzilla 10262.
  +
   Other changes:
   --
   * Shipped XML parser is now Xerces 2.4.0
  
  
  
  1.73  +5 -1  ant/src/main/org/apache/tools/ant/taskdefs/Jar.java
  
  Index: Jar.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Jar.java,v
  retrieving revision 1.72
  retrieving revision 1.73
  diff -u -r1.72 -r1.73
  --- Jar.java  22 Mar 2003 09:39:46 -  1.72
  +++ Jar.java  2 Apr 2003 16:01:15 -   1.73
  @@ -466,7 +466,7 @@
   }
   
   /**
  - * Overriden from Zip class to deal with manifests
  + * Overriden from Zip class to deal with manifests and index lists.
*/
   protected void zipFile(InputStream is, ZipOutputStream zOut, String 
vPath,
  long lastModified, File fromArchive, int mode)
  @@ -475,6 +475,10 @@
   if (! doubleFilePass || (doubleFilePass  skipWriting)) {
   filesetManifest(fromArchive, is);
   }
  +} else if (INDEX_NAME.equalsIgnoreCase(vPath)  index) {
  +log(Warning: selected  + archiveType
  ++  files include a META-INF/INDEX.LIST which will
  ++  be replaced by a newly generated one., 
Project.MSG_WARN);
   } else {
   super.zipFile(is, zOut, vPath, lastModified, fromArchive, mode);
   }
  
  
  


cvs commit: ant/src/testcases/org/apache/tools/ant/taskdefs JarTest.java

2003-04-02 Thread bodewig
bodewig 2003/04/02 08:20:14

  Modified:src/etc/testcases/taskdefs jar.xml
   src/testcases/org/apache/tools/ant/taskdefs JarTest.java
  Log:
  Make sure that streams get closed
  
  Revision  ChangesPath
  1.12  +4 -2  ant/src/etc/testcases/taskdefs/jar.xml
  
  Index: jar.xml
  ===
  RCS file: /home/cvs/ant/src/etc/testcases/taskdefs/jar.xml,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- jar.xml   2 Apr 2003 15:53:37 -   1.11
  +++ jar.xml   2 Apr 2003 16:20:13 -   1.12
  @@ -201,11 +201,13 @@
   unzip src=${tmp.jar} dest=${tmp.dir}/
 /target
   
  -  !-- bug 10262 --
  -  target name=testNoDuplicateIndex
  +  !-- bugs 10262 and 16972 --
  +  target name=testIndexTests
   mkdir dir=${tmp.dir}/META-INF/
   touch file=${tmp.dir}/META-INF/INDEX.LIST/
   touch file=${tmp.dir}/foo/
  +mkdir dir=${tmp.dir}/sub/
  +touch file=${tmp.dir}/sub/foo/
   jar destfile=${tmp.jar} index=yes basedir=${tmp.dir}/
 /target
   /project
  
  
  
  1.21  +56 -9 
ant/src/testcases/org/apache/tools/ant/taskdefs/JarTest.java
  
  Index: JarTest.java
  ===
  RCS file: 
/home/cvs/ant/src/testcases/org/apache/tools/ant/taskdefs/JarTest.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -r1.20 -r1.21
  --- JarTest.java  2 Apr 2003 15:53:38 -   1.20
  +++ JarTest.java  2 Apr 2003 16:20:13 -   1.21
  @@ -54,8 +54,11 @@
   
   package org.apache.tools.ant.taskdefs;
   
  +import java.io.BufferedReader;
   import java.io.File;
   import java.io.FileReader;
  +import java.io.InputStream;
  +import java.io.InputStreamReader;
   import java.io.IOException;
   import java.io.Reader;
   import java.util.Date;
  @@ -230,17 +233,61 @@
   assertTrue(jarXml.exists());
   }
   
  +// bugzilla report 10262
   public void testNoDuplicateIndex() throws IOException {
  -executeTarget(testNoDuplicateIndex);
  -ZipFile archive = new ZipFile(getProject().resolveFile(tempJar));
  -Enumeration enum = archive.entries();
  -int numberOfIndexLists = 0;
  -while (enum.hasMoreElements()) {
  -ZipEntry ze = (ZipEntry) enum.nextElement();
  -if (ze.getName().equals(META-INF/INDEX.LIST)) {
  -numberOfIndexLists++;
  +ZipFile archive = null;
  +try {
  +executeTarget(testIndexTests);
  +archive = new ZipFile(getProject().resolveFile(tempJar));
  +Enumeration enum = archive.entries();
  +int numberOfIndexLists = 0;
  +while (enum.hasMoreElements()) {
  +ZipEntry ze = (ZipEntry) enum.nextElement();
  +if (ze.getName().equals(META-INF/INDEX.LIST)) {
  +numberOfIndexLists++;
  +}
  +}
  +assertEquals(1, numberOfIndexLists);
  +} finally {
  +if (archive != null) {
  +archive.close();
  +}
  +}
  +}
  +
  +// bugzilla report 16972
  +public void XtestRootFilesInIndex() throws IOException {
  +ZipFile archive = null;
  +try {
  +executeTarget(testIndexTests);
  +archive = new ZipFile(getProject().resolveFile(tempJar));
  +ZipEntry ze = archive.getEntry(META-INF/INDEX.LIST);
  +InputStream is = archive.getInputStream(ze);
  +BufferedReader r = new BufferedReader(new InputStreamReader(is,
  +
UTF8));
  +boolean foundSub = false;
  +boolean foundSubFoo = false;
  +boolean foundFoo = false;
  +
  +String line = r.readLine();
  +while (line != null) {
  +if (line.equals(foo)) {
  +foundFoo = true;
  +} else if (line.equals(sub)) {
  +foundSub = true;
  +} else if (line.equals(sub/foo)) {
  +foundSubFoo = true;
  +}
  +line = r.readLine();
  +}
  +
  +assertTrue(foundSub);
  +assertTrue(!foundSubFoo);
  +assertTrue(foundFoo);
  +} finally {
  +if (archive != null) {
  +archive.close();
   }
   }
  -assertEquals(1, numberOfIndexLists);
   }
   }
  
  
  


cvs commit: ant/src/testcases/org/apache/tools/ant/taskdefs JarTest.java

2003-04-03 Thread bodewig
bodewig 2003/04/02 22:06:01

  Modified:src/testcases/org/apache/tools/ant/taskdefs JarTest.java
  Log:
  Demonstrate bug 16972
  
  Revision  ChangesPath
  1.22  +1 -1  
ant/src/testcases/org/apache/tools/ant/taskdefs/JarTest.java
  
  Index: JarTest.java
  ===
  RCS file: 
/home/cvs/ant/src/testcases/org/apache/tools/ant/taskdefs/JarTest.java,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -r1.21 -r1.22
  --- JarTest.java  2 Apr 2003 16:20:13 -   1.21
  +++ JarTest.java  3 Apr 2003 06:06:00 -   1.22
  @@ -256,7 +256,7 @@
   }
   
   // bugzilla report 16972
  -public void XtestRootFilesInIndex() throws IOException {
  +public void testRootFilesInIndex() throws IOException {
   ZipFile archive = null;
   try {
   executeTarget(testIndexTests);
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs Jar.java

2003-04-03 Thread bodewig
bodewig 2003/04/02 22:41:51

  Modified:.WHATSNEW
   src/main/org/apache/tools/ant/taskdefs Jar.java
  Log:
  Improve standards compliance of created index.
  
  PR: 16972
  
  Revision  ChangesPath
  1.387 +3 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.386
  retrieving revision 1.387
  diff -u -r1.386 -r1.387
  --- WHATSNEW  2 Apr 2003 16:01:15 -   1.386
  +++ WHATSNEW  3 Apr 2003 06:41:50 -   1.387
  @@ -84,6 +84,9 @@
   
   * jar index=on could include multiple index lists.  Bugzilla 10262.
   
  +* The index created by jar didn't conform to the spec as it didn't
  +  include the top-level entries.  Bugzilla Report 16972.
  +
   Other changes:
   --
   * Shipped XML parser is now Xerces 2.4.0
  
  
  
  1.74  +28 -7 ant/src/main/org/apache/tools/ant/taskdefs/Jar.java
  
  Index: Jar.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Jar.java,v
  retrieving revision 1.73
  retrieving revision 1.74
  diff -u -r1.73 -r1.74
  --- Jar.java  2 Apr 2003 16:01:15 -   1.73
  +++ Jar.java  3 Apr 2003 06:41:51 -   1.74
  @@ -67,6 +67,7 @@
   import java.io.PrintWriter;
   import java.io.Reader;
   import java.util.Enumeration;
  +import java.util.Vector;
   import java.util.zip.ZipEntry;
   import java.util.zip.ZipFile;
   import org.apache.tools.ant.BuildException;
  @@ -145,12 +146,24 @@
*/
   private boolean createEmpty = false;
   
  +/**
  + * Stores all files that are in the root of the archive (i.e. that
  + * have a name that doesn't contain a slash) so they can get
  + * listed in the index.
  + *
  + * Will not be filled unless the user has asked for an index.
  + *
  + * @since Ant 1.6
  + */
  +private Vector rootEntries;
  +
   /** constructor */
   public Jar() {
   super();
   archiveType = jar;
   emptyBehavior = create;
   setEncoding(UTF8);
  +rootEntries = new Vector();
   }
   
   /**
  @@ -458,6 +471,11 @@
   writer.println(dir);
   }
   
  +enum = rootEntries.elements();
  +while (enum.hasMoreElements()) {
  +writer.println(enum.nextElement());
  +}
  +
   writer.flush();
   ByteArrayInputStream bais =
   new ByteArrayInputStream(baos.toByteArray());
  @@ -480,6 +498,9 @@
   +  files include a META-INF/INDEX.LIST which will
   +  be replaced by a newly generated one., 
Project.MSG_WARN);
   } else {
  +if (index  vPath.indexOf(/) == -1) {
  +rootEntries.addElement(vPath);
  +}
   super.zipFile(is, zOut, vPath, lastModified, fromArchive, mode);
   }
   }
  @@ -663,13 +684,13 @@
   super.cleanUp();
   
   // we want to save this info if we are going to make another pass
  -if (! doubleFilePass || (doubleFilePass  ! skipWriting))
  -{
  -manifest = null;
  -configuredManifest = savedConfiguredManifest;
  -filesetManifest = null;
  -originalManifest = null;
  -}
  +if (! doubleFilePass || (doubleFilePass  ! skipWriting)) {
  +manifest = null;
  +configuredManifest = savedConfiguredManifest;
  +filesetManifest = null;
  +originalManifest = null;
  +}
  +rootEntries.removeAllElements();
   }
   
   /**
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/jdepend JDependTask.java

2003-04-03 Thread bodewig
bodewig 2003/04/03 07:49:48

  Modified:docs/manual/OptionalTasks jdepend.html
   src/main/org/apache/tools/ant/taskdefs/optional/jdepend
JDependTask.java
  Log:
  Apply some reflection to become JDepend version independent
  
  Revision  ChangesPath
  1.10  +1 -1  ant/docs/manual/OptionalTasks/jdepend.html
  
  Index: jdepend.html
  ===
  RCS file: /home/cvs/ant/docs/manual/OptionalTasks/jdepend.html,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- jdepend.html  2 Apr 2003 12:00:27 -   1.9
  +++ jdepend.html  3 Apr 2003 15:49:47 -   1.10
  @@ -93,7 +93,7 @@
   the paths of compiled class code to analyze; the lt;sourcespathgt;
   variable is still available in case you are using an earlier version
   of JDepend.  The lt;excludegt; element can be used to set packages
  -to ignore./p
  +to ignore (requires JDepend 2.5 or above)./p
   
   h3Examples/h3
   
  
  
  
  1.19  +48 -17
ant/src/main/org/apache/tools/ant/taskdefs/optional/jdepend/JDependTask.java
  
  Index: JDependTask.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/jdepend/JDependTask.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- JDependTask.java  2 Apr 2003 12:00:27 -   1.18
  +++ JDependTask.java  3 Apr 2003 15:49:48 -   1.19
  @@ -58,6 +58,8 @@
   import java.io.FileWriter;
   import java.io.IOException;
   import java.io.PrintWriter;
  +import java.lang.reflect.Constructor;
  +import java.lang.reflect.Method;
   import java.util.Vector;
   import org.apache.tools.ant.BuildException;
   import org.apache.tools.ant.PathTokenizer;
  @@ -104,19 +106,37 @@
   private String format = text;
   private PatternSet defaultPatterns = new PatternSet();
   
  -public JDependTask() {
  +private static Constructor packageFilterC;
  +private static Method setFilter;
   
  +static {
  +try {
  +Class packageFilter = 
  +Class.forName(jdepend.framework.PackageFilter);
  +packageFilterC = 
  +packageFilter.getConstructor(new Class[] 
{java.util.Collection.class});
  +setFilter = 
  +jdepend.textui.JDepend.class.getDeclaredMethod(setFilter,
  +   new Class[] 
{packageFilter});
  +} catch (Throwable t) {
  +if (setFilter == null) {
  +packageFilterC = null;
  +}
  +}
   }
   
  -/*
  -public void setTimeout(Integer value) {
  -_timeout = value;
  +public JDependTask() {
   }
   
  -public Integer getTimeout() {
  -return _timeout;
  -}
  -*/
  +/*
  +  public void setTimeout(Integer value) {
  +  _timeout = value;
  +  }
  +
  +  public Integer getTimeout() {
  +  return _timeout;
  +  }
  +*/
   
   /**
* The output file name.
  @@ -305,9 +325,9 @@
   if (text.equals(format)) {
   commandline.setClassname(jdepend.textui.JDepend);
   } else
  -if (xml.equals(format)) {
  -commandline.setClassname(jdepend.xmlui.JDepend);
  -}
  +if (xml.equals(format)) {
  +commandline.setClassname(jdepend.xmlui.JDepend);
  +}
   
   if (_jvm != null) {
   commandline.setVm(_jvm);
  @@ -443,11 +463,22 @@
   // This bit turns exclude child tags into patters to ignore
   String[] patterns = defaultPatterns.getExcludePatterns(getProject());
   if (patterns != null  patterns.length  0) {
  -Vector v = new Vector();
  -for (int i = 0; i  patterns.length; i++) {
  -v.addElement(patterns[i]);
  +if (setFilter != null) {
  +Vector v = new Vector();
  +for (int i = 0; i  patterns.length; i++) {
  +v.addElement(patterns[i]);
  +}
  +try {
  +Object o = packageFilterC.newInstance(new Object[] {v});
  +setFilter.invoke(jdepend, new Object[] {o});
  +} catch (Throwable e) {
  +log(excludes will be ignored as JDepend doesn't like 
me: 
  ++ e.getMessage(), Project.MSG_WARN);
  +}
  +} else {
  +log(Sorry, your version of JDepend doesn't support 
excludes,
  +Project.MSG_WARN);
   }
  -jdepend.setFilter(new jdepend.framework.PackageFilter(v));
   }
   
   jdepend.analyze();
  @@ -493,7 +524,7 @@
   // not necessary as JDepend would fail, but why loose some

cvs commit: ant/src/main/org/apache/tools/ant/util DOMElementWriter.java

2003-04-04 Thread bodewig
bodewig 2003/04/04 00:36:22

  Modified:src/main/org/apache/tools/ant/taskdefs/optional/junit
XMLJUnitResultFormatter.java
XMLResultAggregator.java XalanExecutor.java
   src/main/org/apache/tools/ant/util DOMElementWriter.java
  Log:
  Speed up junitreport by buffering output.
  
  Vastly reduce memory requirements of DOMElementWriter on JDK 1.4.1 by
  using the workaround for JDK 1.4.1's StringBuffer#toString memory leak
  (JDC BugParade Bug 4724129).
  
  PR: 18504
  Submitted by: Andrus Adamchik mensk at users dot sourceforge dot net
  
  Revision  ChangesPath
  1.28  +2 -1  
ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/XMLJUnitResultFormatter.java
  
  Index: XMLJUnitResultFormatter.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/XMLJUnitResultFormatter.java,v
  retrieving revision 1.27
  retrieving revision 1.28
  diff -u -r1.27 -r1.28
  --- XMLJUnitResultFormatter.java  28 Mar 2003 12:20:51 -  1.27
  +++ XMLJUnitResultFormatter.java  4 Apr 2003 08:36:22 -   1.28
  @@ -54,6 +54,7 @@
   
   package org.apache.tools.ant.taskdefs.optional.junit;
   
  +import java.io.BufferedWriter;
   import java.io.IOException;
   import java.io.OutputStream;
   import java.io.OutputStreamWriter;
  @@ -165,7 +166,7 @@
   if (out != null) {
   Writer wri = null;
   try {
  -wri = new OutputStreamWriter(out, UTF8);
  +wri = new BufferedWriter(new OutputStreamWriter(out, 
UTF8));
   wri.write(?xml version=\1.0\ encoding=\UTF-8\ ?\n);
   (new DOMElementWriter()).write(rootElement, wri, 0,   );
   wri.flush();
  
  
  
  1.22  +3 -2  
ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/XMLResultAggregator.java
  
  Index: XMLResultAggregator.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/XMLResultAggregator.java,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -r1.21 -r1.22
  --- XMLResultAggregator.java  10 Feb 2003 14:14:16 -  1.21
  +++ XMLResultAggregator.java  4 Apr 2003 08:36:22 -   1.22
  @@ -1,7 +1,7 @@
   /*
* The Apache Software License, Version 1.1
*
  - * Copyright (c) 2001-2002 The Apache Software Foundation.  All rights
  + * Copyright (c) 2001-2003 The Apache Software Foundation.  All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
  @@ -53,6 +53,7 @@
*/
   package org.apache.tools.ant.taskdefs.optional.junit;
   
  +import java.io.BufferedOutputStream;
   import java.io.File;
   import java.io.FileOutputStream;
   import java.io.IOException;
  @@ -228,7 +229,7 @@
   OutputStream out = null;
   PrintWriter wri = null;
   try {
  -out = new FileOutputStream(file);
  +out = new BufferedOutputStream(new FileOutputStream(file));
   wri = new PrintWriter(new OutputStreamWriter(out, UTF8));
   wri.write(?xml version=\1.0\ encoding=\UTF-8\ ?\n);
   (new DOMElementWriter()).write(doc.getDocumentElement(), wri, 0, 
  );
  
  
  
  1.9   +3 -2  
ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/XalanExecutor.java
  
  Index: XalanExecutor.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/XalanExecutor.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- XalanExecutor.java10 Feb 2003 14:14:16 -  1.8
  +++ XalanExecutor.java4 Apr 2003 08:36:22 -   1.9
  @@ -53,6 +53,7 @@
*/
   package org.apache.tools.ant.taskdefs.optional.junit;
   
  +import java.io.BufferedOutputStream;
   import java.io.ByteArrayOutputStream;
   import java.io.File;
   import java.io.FileOutputStream;
  @@ -81,12 +82,12 @@
   
   /** get the appropriate stream based on the format (frames/noframes) */
   protected OutputStream getOutputStream() throws IOException {
  -if (caller.FRAMES.equals(caller.format)){
  +if (AggregateTransformer.FRAMES.equals(caller.format)){
   // dummy output for the framed report
   // it's all done by extension...
   return new ByteArrayOutputStream();
   } else {
  -return new FileOutputStream(new File(caller.toDir, 
junit-noframes.html));
  +return new BufferedOutputStream(new FileOutputStream(new 
File(caller.toDir, junit-noframes.html)));
   }
   }
   
  
  
  
  1.17  +5 -4  
ant/src/main/org/apache/tools/ant/util/DOMElementWriter.java
  
  Index: DOMElementWriter.java

cvs commit: ant/docs/manual/CoreTasks sql.html

2003-04-04 Thread bodewig
bodewig 2003/04/04 00:50:08

  Modified:docs/manual/CoreTasks sql.html
  Log:
  Sync docs with new functionality.
  
  Submitted by: Rob Anderson Anderson dot Rob at vectorscm dot com
  
  Revision  ChangesPath
  1.19  +8 -1  ant/docs/manual/CoreTasks/sql.html
  
  Index: sql.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/sql.html,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- sql.html  18 Dec 2002 17:27:00 -  1.18
  +++ sql.html  4 Apr 2003 08:50:07 -   1.19
  @@ -132,6 +132,13 @@
 td width=10% valign=topNo (defaul:normal)/td
   /tr
   
  +tr
  +  td width=12% valign=topkeepformat/td
  +  td width=78% valign=topControl whether the format of the sql will be 
preserved.br
  +Usefull when loading packages and procedures.
  +  td width=10% valign=topNo (defaul=false)/td
  +/tr
  +
   /table
   
   h3Parameters specified as nested elements/h3
  @@ -295,7 +302,7 @@
   /pre/blockquote
   
   hr
  -p align=centerCopyright copy; 2000-2002 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2000-2003 Apache Software Foundation. All 
rights
   Reserved./p
   /body
   /html
  
  
  


cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/javacc JJTree.java JavaCC.java

2003-04-04 Thread bodewig
bodewig 2003/04/04 01:08:52

  Modified:.WHATSNEW
   src/main/org/apache/tools/ant/taskdefs/optional/javacc
JJTree.java JavaCC.java
  Log:
  Make javacc and jjtree work with JavaCC version 3.x.
  
  PR: 18664
  Submitted by: Jene Jasper jjasper at abz dot nl
  
  Revision  ChangesPath
  1.389 +2 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.388
  retrieving revision 1.389
  diff -u -r1.388 -r1.389
  --- WHATSNEW  3 Apr 2003 08:48:47 -   1.388
  +++ WHATSNEW  4 Apr 2003 09:08:51 -   1.389
  @@ -218,6 +218,8 @@
   
   * The JProbe tasks now also work with JProbe 4.x.  Bugzilla Report 14849.
   
  +* javacc and jjtree will now autodetect JavaCC 3.x and can use it.
  +
   Changes from Ant 1.5.2 to Ant 1.5.3
   ===
   
  
  
  
  1.20  +9 -7  
ant/src/main/org/apache/tools/ant/taskdefs/optional/javacc/JJTree.java
  
  Index: JJTree.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/javacc/JJTree.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -r1.19 -r1.20
  --- JJTree.java   18 Feb 2003 12:46:27 -  1.19
  +++ JJTree.java   4 Apr 2003 09:08:52 -   1.20
  @@ -202,7 +202,6 @@
   
   public JJTree() {
   cmdl.setVm(JavaEnvUtils.getJreExecutable(java));
  -cmdl.setClassname(COM.sun.labs.jjtree.Main);
   }
   
   public void execute() throws BuildException {
  @@ -218,30 +217,33 @@
   if (target == null || !target.isFile()) {
   throw new BuildException(Invalid target:  + target);
   }
  -
  +
   // use the directory containing the target as the output directory
   if (outputDirectory == null) {
   outputDirectory = new File(target.getParent());
  -}
  +}
   if (!outputDirectory.isDirectory()) {
  -throw new BuildException('outputdirectory'  + outputDirectory 
  +throw new BuildException('outputdirectory'  + outputDirectory
   +  is not a directory.);
   }
   // convert backslashes to slashes, otherwise jjtree will put this as
   // comments and this seems to confuse javacc
  -cmdl.createArgument().setValue(-OUTPUT_DIRECTORY: 
  +cmdl.createArgument().setValue(-OUTPUT_DIRECTORY:
   + outputDirectory.getAbsolutePath().replace('\\', '/'));
  -
  +
   String targetName = target.getName();
   final File javaFile = new File(outputDirectory,
   targetName.substring(0, targetName.indexOf(.jjt)) + .jj);
  -if (javaFile.exists() 
  +if (javaFile.exists()
 target.lastModified()  javaFile.lastModified()) {
   log(Target is already built - skipping ( + target + ),
   Project.MSG_VERBOSE);
   return;
   }
   cmdl.createArgument().setValue(target.getAbsolutePath());
  +
  +cmdl.setClassname(JavaCC.getMainClass(javaccHome, 
  +  JavaCC.TASKDEF_TYPE_JJTREE));
   
   final Path classpath = cmdl.createClasspath(getProject());
   final File javaccJar = JavaCC.getArchiveFile(javaccHome);
  
  
  
  1.22  +115 -16   
ant/src/main/org/apache/tools/ant/taskdefs/optional/javacc/JavaCC.java
  
  Index: JavaCC.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/javacc/JavaCC.java,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -r1.21 -r1.22
  --- JavaCC.java   18 Feb 2003 12:46:27 -  1.21
  +++ JavaCC.java   4 Apr 2003 09:08:52 -   1.22
  @@ -106,6 +106,23 @@
   
   private CommandlineJava cmdl = new CommandlineJava();
   
  +protected static final int TASKDEF_TYPE_JAVACC = 1;
  +protected static final int TASKDEF_TYPE_JJTREE = 2;
  +protected static final int TASKDEF_TYPE_JJDOC = 3;
  +
  +protected static final String[] ARCHIVE_LOCATIONS = 
  +new String[] {JavaCC.zip, bin/lib/JavaCC.zip, 
  +  bin/lib/javacc.jar};
  +
  +protected static final String COM_PACKAGE = COM.sun.labs.;
  +protected static final String COM_JAVACC_CLASS = javacc.Main;
  +protected static final String COM_JJTREE_CLASS = jjtree.Main;
  +protected static final String COM_JJDOC_CLASS = jjdoc.JJDocMain;
  +
  +protected static final String ORG_PACKAGE = org.netbeans.javacc.;
  +protected static final String ORG_JAVACC_CLASS = parser.Main;
  +protected static final String ORG_JJTREE_CLASS = COM_JJTREE_CLASS;
  +protected static final String ORG_JJDOC_CLASS

cvs commit: ant/src/main/org/apache/tools/ant/taskdefs/optional/perforce P4Fstat.java

2003-04-04 Thread bodewig
bodewig 2003/04/04 05:02:40

  Modified:src/main/org/apache/tools/ant/taskdefs/optional/perforce
P4Fstat.java
  Log:
  Remove stray CRs
  
  Revision  ChangesPath
  1.4   +213 -212  
ant/src/main/org/apache/tools/ant/taskdefs/optional/perforce/P4Fstat.java
  
  Index: P4Fstat.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/perforce/P4Fstat.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- P4Fstat.java  10 Feb 2003 14:14:19 -  1.3
  +++ P4Fstat.java  4 Apr 2003 13:02:40 -   1.4
  @@ -1,214 +1,215 @@
  -/*
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 2003 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *notice, this list of conditions and the following disclaimer in
  - *the documentation and/or other materials provided with the
  - *distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *any, must include the following acknowlegement:
  - *   This product includes software developed by the
  - *Apache Software Foundation (http://www.apache.org/).
  - *Alternately, this acknowlegement may appear in the software itself,
  - *if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names Ant and Apache Software
  - *Foundation must not be used to endorse or promote products derived
  - *from this software without prior written permission. For written
  - *permission, please contact [EMAIL PROTECTED]
  - *
  - * 5. Products derived from this software may not be called Apache
  - *nor may Apache appear in their names without prior written
  - *permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * 
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * http://www.apache.org/.
  - */
  -/*
  - * Portions of this software are based upon public domain software
  - * originally written at the National Center for Supercomputing Applications,
  - * University of Illinois, Urbana-Champaign.
  - */
  -
  -package org.apache.tools.ant.taskdefs.optional.perforce;
  -
  -
  -import java.io.File;
  -import java.util.Vector;
  -import java.util.ArrayList;
  -
  -import org.apache.tools.ant.BuildException;
  -import org.apache.tools.ant.DirectoryScanner;
  -import org.apache.tools.ant.Project;
  -import org.apache.tools.ant.types.FileSet;
  -
  -/**
  - * P4Fstat  - find out which files are under Perforce control and which are 
not.
  - *
  - * brbExample Usage:/bbr
  - * pre
  - * lt;project name=quot;p4fstatquot; default=quot;p4fstatquot; 
basedir=quot;C:\dev\gnuquot;gt;
  - * lt;target name=quot;p4fstatquot; gt;
  - * lt;p4fstat showfilter=quot;allquot;gt;
  - * lt;fileset dir=quot;depotquot; 
includes=quot;**\/*quot;/gt;
  - * lt;/p4fstatgt;
  - * lt;/targetgt;
  - * lt;/projectgt;
  - * /pre
  - *
  - * @author A HREF=mailto:[EMAIL PROTECTED]Miha/A
  - * @author A HREF=mailto:[EMAIL PROTECTED]Les Hughes/A
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 2003 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *notice, this list

cvs commit: ant/src/main/org/apache/tools/ant/util DOMElementWriter.java RegexpPatternMapper.java ResourceUtils.java

2003-04-04 Thread bodewig
bodewig 2003/04/04 05:51:12

  Modified:src/main/org/apache/tools/ant RuntimeConfigurable.java
   src/main/org/apache/tools/ant/listener MailLogger.java
   src/main/org/apache/tools/ant/taskdefs AntStructure.java
Concat.java FixCRLF.java Javadoc.java Replace.java
SQLExec.java
   src/main/org/apache/tools/ant/taskdefs/email Message.java
   src/main/org/apache/tools/ant/taskdefs/optional
ReplaceRegExp.java
   src/main/org/apache/tools/ant/taskdefs/optional/junit
JUnitTask.java
   src/main/org/apache/tools/ant/taskdefs/optional/perforce
P4Add.java P4Fstat.java
   src/main/org/apache/tools/ant/taskdefs/optional/sitraka/bytecode
Utils.java
   src/main/org/apache/tools/ant/types Commandline.java
Path.java
   src/main/org/apache/tools/ant/util DOMElementWriter.java
RegexpPatternMapper.java ResourceUtils.java
  Log:
  Avoid reusing StringBuffers to work around JDK 1.4.1 memory leak.
  
  I'm sure that my changes in most cases are of the paranoid type,
  ResourceUtils and FixCRLF look as if they really had a chance of
  running into trouble.
  
  Revision  ChangesPath
  1.29  +1 -1  
ant/src/main/org/apache/tools/ant/RuntimeConfigurable.java
  
  Index: RuntimeConfigurable.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/RuntimeConfigurable.java,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -r1.28 -r1.29
  --- RuntimeConfigurable.java  2 Apr 2003 11:43:41 -   1.28
  +++ RuntimeConfigurable.java  4 Apr 2003 13:51:11 -   1.29
  @@ -324,7 +324,7 @@
   id = (String) attributeMap.get(id);
   
   if (characters.length() != 0) {
  -ProjectHelper.addText(p, wrappedObject, characters.toString());
  +ProjectHelper.addText(p, wrappedObject, characters.substring(0));
   }
   
   Enumeration enum = children.elements();
  
  
  
  1.15  +2 -2  
ant/src/main/org/apache/tools/ant/listener/MailLogger.java
  
  Index: MailLogger.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/listener/MailLogger.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- MailLogger.java   10 Feb 2003 14:13:34 -  1.14
  +++ MailLogger.java   4 Apr 2003 13:51:11 -   1.15
  @@ -1,7 +1,7 @@
   /*
* The Apache Software License, Version 1.1
*
  - * Copyright (c) 2002-2002 The Apache Software Foundation.  All rights
  + * Copyright (c) 2002-2003 The Apache Software Foundation.  All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
  @@ -158,7 +158,7 @@
   String subject = getValue(properties, prefix + .subject,
   (success) ? Build Success : Build Failure);
   
  -sendMail(mailhost, port, from, toList, subject, 
buffer.toString());
  +sendMail(mailhost, port, from, toList, subject, 
buffer.substring(0));
   } catch (Exception e) {
   System.out.println(MailLogger failed to send e-mail!);
   e.printStackTrace(System.err);
  
  
  
  1.32  +4 -4  
ant/src/main/org/apache/tools/ant/taskdefs/AntStructure.java
  
  Index: AntStructure.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/AntStructure.java,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -r1.31 -r1.32
  --- AntStructure.java 7 Mar 2003 11:23:00 -   1.31
  +++ AntStructure.java 4 Apr 2003 13:51:11 -   1.32
  @@ -1,7 +1,7 @@
   /*
* The Apache Software License, Version 1.1
*
  - * Copyright (c) 2000-2002 The Apache Software Foundation.  All rights
  + * Copyright (c) 2000-2003 The Apache Software Foundation.  All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
  @@ -294,8 +294,8 @@
   sb.append();
   out.println(sb);
   
  -sb.setLength(0);
  -sb.append(!ATTLIST ).append(name);
  +sb = new StringBuffer(!ATTLIST );
  +sb.append(name);
   sb.append(lSep).append(  id ID #IMPLIED);
   
   enum = ih.getAttributes();
  
  
  
  1.18  +2 -2  ant/src/main/org/apache/tools/ant/taskdefs/Concat.java
  
  Index: Concat.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Concat.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -r1.17 -r1.18
  --- Concat.java   28 Mar

cvs commit: ant/docs/manual/CoreTasks input.html

2003-04-07 Thread bodewig
bodewig 2003/04/07 09:05:57

  Modified:docs/manual/CoreTasks input.html
  Log:
  Document input's defaultvalue attribute.
  
  PR: 18717
  Submitted by: Jan Matèrne jan at materne dot de
  
  Revision  ChangesPath
  1.8   +17 -1 ant/docs/manual/CoreTasks/input.html
  
  Index: input.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/input.html,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- input.html4 Sep 2002 11:05:16 -   1.7
  +++ input.html7 Apr 2003 16:05:57 -   1.8
  @@ -56,6 +56,13 @@
   overriden./td
   td valign=top align=centerNo/td
 /tr
  +  tr
  +td valign=topdefaultvalue/td
  +td valign=topDefines the default value of the property to be
  +created from input.  Property value will be set to default if no
  +input is received./td
  +td valign=top align=centerNo/td
  +  /tr
   /table
   h3Examples/h3
   pre  lt;input/gt;/pre
  @@ -95,8 +102,17 @@
   pWill display the message quot;Please enter db-username:quot; and set the
   property codedb.user/code to the value entered by the user./p
   
  +pre  lt;input
  +message=quot;Please enter db-username:quot;
  +addproperty=quot;db.userquot;
  +defaultvalue=quot;Scott-Tigerquot;
  +  /gt;/pre
  +pSame as above, but will set codedb.user/code to the value
  +iScott- Tiger/i if the user enters no value (simply types
  +lt;returngt;)./p
  +
   hr
  -p align=centerCopyright copy; 2001-2002 Apache Software Foundation. All 
rights
  +p align=centerCopyright copy; 2001-2003 Apache Software Foundation. All 
rights
   Reserved./p
   /body
   /html
  
  
  


  1   2   3   4   5   6   7   8   9   10   >