Home | History | Annotate | Download | only in scripts_bugzilla
      1 #!/bin/sh
      2 
      3 export JAVA_HOME=/opt/sun-java2-1.4;
      4 export ANT_HOME=/opt/apache-ant-1.6;
      5 
      6 #aasemble the command and its classpath
      7 CLASSPATH="$JAVA_HOME/lib/rt.jar";
      8 # note that com.sun.org.apache.xerces (Sun JDK 1.5, rt.jar) != org.apache.xerces (Ant 1.6.5, xercesImpl.jar) so must remove from classpath
      9 #for f in `find $ANT_HOME/lib  -maxdepth 1 -name "*.jar" -type f -not -name "xercesImpl.jar"`; do CLASSPATH=$CLASSPATH":"$f; done
     10 CLASSPATH=$CLASSPATH":"$ANT_HOME/lib/ant.jar":"$ANT_HOME/lib/ant-launcher.jar;
     11 cmd="$JAVA_HOME/bin/java \
     12   -Dant.home=$ANT_HOME \
     13   -Dant.library.dir=$JAVA_HOME/lib \
     14   -classpath $CLASSPATH:../bugTools.jar \
     15   org.apache.tools.ant.launch.Launcher \
     16   -buildfile updateBugState.xml";
     17 
     18 if [[ $debug -gt 0 ]]; then 
     19 	echo "Running ..."; echo ""; echo $cmd | sed -e "s/ \-/#  \-/g" -e "s/:/#    :/g" | tr "#" "\n"; echo "";
     20 fi
     21 
     22 # run the command
     23 $cmd;
     24