From 833d29b9e0dac737fb1608740c7582b54d462b5c Mon Sep 17 00:00:00 2001 From: "Andrew C. Oliver" Date: Thu, 31 Jan 2002 02:22:28 +0000 Subject: Initial revision git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@352063 13f79535-47bb-0310-9956-ffa450edef68 --- tools/.cvsignore | 1 + tools/bin/ant | 107 +++++++++ tools/bin/ant.bat | 97 +++++++++ tools/bin/antRun | 9 + tools/bin/antRun.bat | 20 ++ tools/bin/fix-packages.py | 216 ++++++++++++++++++ tools/bin/lcp.bat | 2 + tools/bin/runant.pl | 131 +++++++++++ tools/lib/.cvsignore | 3 + tools/lib/ant-1.4.1-optional.jar | Bin 0 -> 468566 bytes tools/lib/ant-1.4.1.jar | Bin 0 -> 417110 bytes tools/lib/jtidy-04aug2000r7-dev.jar | Bin 0 -> 161826 bytes tools/lib/junit.jar | Bin 0 -> 117522 bytes tools/lib/xalan-2.2.0.jar | Bin 0 -> 923866 bytes tools/resources/Release-Checklist.txt | 18 ++ tools/resources/jindent/poi.jin | 319 +++++++++++++++++++++++++++ tools/resources/stylesheets/html2xml.xsl | 153 +++++++++++++ tools/src/ClassAvailable.java | 246 +++++++++++++++++++++ tools/src/JTidyTask.java | 272 +++++++++++++++++++++++ tools/src/SitemapTool.java | 363 +++++++++++++++++++++++++++++++ tools/src/UserInput.java | 151 +++++++++++++ tools/src/XConfTool.java | 238 ++++++++++++++++++++ tools/src/announcement2header.xsl | 78 +++++++ tools/src/announcement2readme.xsl | 89 ++++++++ tools/src/announcement2site.xsl | 92 ++++++++ tools/src/announcement2txt.xsl | 174 +++++++++++++++ tools/src/bugzilla2patchqueue.xsl | 36 +++ tools/src/changelog.xsl | 95 ++++++++ tools/src/patchqueue2text4dev.xsl | 70 ++++++ tools/src/patchqueue2xdocs.xsl | 109 ++++++++++ 30 files changed, 3089 insertions(+) create mode 100755 tools/.cvsignore create mode 100755 tools/bin/ant create mode 100755 tools/bin/ant.bat create mode 100755 tools/bin/antRun create mode 100755 tools/bin/antRun.bat create mode 100755 tools/bin/fix-packages.py create mode 100755 tools/bin/lcp.bat create mode 100755 tools/bin/runant.pl create mode 100755 tools/lib/.cvsignore create mode 100755 tools/lib/ant-1.4.1-optional.jar create mode 100755 tools/lib/ant-1.4.1.jar create mode 100644 tools/lib/jtidy-04aug2000r7-dev.jar create mode 100755 tools/lib/junit.jar create mode 100644 tools/lib/xalan-2.2.0.jar create mode 100755 tools/resources/Release-Checklist.txt create mode 100755 tools/resources/jindent/poi.jin create mode 100755 tools/resources/stylesheets/html2xml.xsl create mode 100644 tools/src/ClassAvailable.java create mode 100644 tools/src/JTidyTask.java create mode 100644 tools/src/SitemapTool.java create mode 100644 tools/src/UserInput.java create mode 100644 tools/src/XConfTool.java create mode 100755 tools/src/announcement2header.xsl create mode 100755 tools/src/announcement2readme.xsl create mode 100755 tools/src/announcement2site.xsl create mode 100755 tools/src/announcement2txt.xsl create mode 100755 tools/src/bugzilla2patchqueue.xsl create mode 100755 tools/src/changelog.xsl create mode 100755 tools/src/patchqueue2text4dev.xsl create mode 100755 tools/src/patchqueue2xdocs.xsl (limited to 'tools') diff --git a/tools/.cvsignore b/tools/.cvsignore new file mode 100755 index 0000000000..d84cd14c25 --- /dev/null +++ b/tools/.cvsignore @@ -0,0 +1 @@ +anttasks diff --git a/tools/bin/ant b/tools/bin/ant new file mode 100755 index 0000000000..4555bf7089 --- /dev/null +++ b/tools/bin/ant @@ -0,0 +1,107 @@ +#! /bin/sh + +if [ -f "$HOME/.antrc" ] ; then + . $HOME/.antrc +fi + +# Cygwin support. $cygwin _must_ be set to either true or false. +case "`uname`" in + CYGWIN*) cygwin=true ;; + *) cygwin=false ;; +esac + +# For Cygwin, ensure paths are in UNIX format before anything is touched +if $cygwin; then + [ -n "$ANT_HOME" ] && + ANT_HOME=`cygpath --unix "$ANT_HOME"` + [ -n "$JAVA_HOME" ] && + JAVA_HOME=`cygpath --unix "$JAVA_HOME"` + [ -n "$CLASSPATH" ] && + CLASSPATH=`cygpath --path --unix "$CLASSPATH"` +fi + +if [ "$ANT_HOME" = "" ] ; then + # try to find ANT + if [ -d /opt/ant ] ; then + ANT_HOME=/opt/ant + fi + + if [ -d ${HOME}/opt/ant ] ; then + ANT_HOME=${HOME}/opt/ant + fi + + ## resolve links - $0 may be a link to ant's home + PRG=$0 + progname=`basename $0` + + while [ -h "$PRG" ] ; do + ls=`ls -ld "$PRG"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '.*/.*' > /dev/null; then + PRG="$link" + else + PRG="`dirname $PRG`/$link" + fi + done + + ANT_HOME=`dirname "$PRG"`/.. + +fi + +if [ "$JAVA_HOME" != "" ] ; then + if [ "$JAVACMD" = "" ] ; then + JAVACMD=$JAVA_HOME/bin/java + fi +else + if [ "$JAVACMD" = "" ] ; then + JAVACMD=java + fi +fi + +# add in the dependency .jar files +DIRLIBS=${ANT_HOME}/lib/*.jar +for i in ${DIRLIBS} +do + # if the directory is empty, then it will return the input string + # this is stupid, so case for it + if [ "$i" != "${DIRLIBS}" ] ; then + LOCALCLASSPATH=$LOCALCLASSPATH:"$i" + fi +done + +if [ "$CLASSPATH" != "" ] ; then + LOCALCLASSPATH=$CLASSPATH:$LOCALCLASSPATH +fi + +if [ "$JAVA_HOME" != "" ] ; then + if test -f $JAVA_HOME/lib/tools.jar ; then + LOCALCLASSPATH=$LOCALCLASSPATH:$JAVA_HOME/lib/tools.jar + fi + + if test -f $JAVA_HOME/lib/classes.zip ; then + LOCALCLASSPATH=$LOCALCLASSPATH:$JAVA_HOME/lib/classes.zip + fi +else + echo "Warning: JAVA_HOME environment variable is not set." + echo " If build fails because sun.* classes could not be found" + echo " you will need to set the JAVA_HOME environment variable" + echo " to the installation directory of java." +fi + +# supply JIKESPATH to Ant as jikes.class.path +if [ "$JIKESPATH" != "" ] ; then + if [ "$ANT_OPTS" != "" ] ; then + ANT_OPTS="$ANT_OPTS -Djikes.class.path=$JIKESPATH" + else + ANT_OPTS=-Djikes.class.path=$JIKESPATH + fi +fi + +# For Cygwin, switch paths to Windows format before running java +if $cygwin; then + ANT_HOME=`cygpath --path --windows "$ANT_HOME"` + JAVA_HOME=`cygpath --path --windows "$JAVA_HOME"` + LOCALCLASSPATH=`cygpath --path --windows "$LOCALCLASSPATH"` +fi + +$JAVACMD -classpath "$LOCALCLASSPATH" -Dant.home="${ANT_HOME}" $ANT_OPTS org.apache.tools.ant.Main "$@" diff --git a/tools/bin/ant.bat b/tools/bin/ant.bat new file mode 100755 index 0000000000..e8f8fd1e80 --- /dev/null +++ b/tools/bin/ant.bat @@ -0,0 +1,97 @@ +@echo off + +if exist "%HOME%\antrc_pre.bat" call "%HOME%\antrc_pre.bat" + +if not "%OS%"=="Windows_NT" goto win9xStart +:winNTStart +@setlocal + +rem %~dp0 is name of current script under NT +set DEFAULT_ANT_HOME=%~dp0 + +rem : operator works similar to make : operator +set DEFAULT_ANT_HOME=%DEFAULT_ANT_HOME:\bin\=% + +if %ANT_HOME%a==a set ANT_HOME=%DEFAULT_ANT_HOME% +set DEFAULT_ANT_HOME= + +rem On NT/2K grab all arguments at once +set ANT_CMD_LINE_ARGS=%* +goto doneStart + +:win9xStart +rem Slurp the command line arguments. This loop allows for an unlimited number of +rem agruments (up to the command line limit, anyway). + +set ANT_CMD_LINE_ARGS= + +:setupArgs +if %1a==a goto doneStart +set ANT_CMD_LINE_ARGS=%ANT_CMD_LINE_ARGS% %1 +shift +goto setupArgs + +:doneStart +rem This label provides a place for the argument list loop to break out +rem and for NT handling to skip to. + +rem find ANT_HOME +if not "%ANT_HOME%"=="" goto checkJava + +rem check for ant in Program Files on system drive +if not exist "%SystemDrive%\Program Files\ant" goto checkSystemDrive +set ANT_HOME=%SystemDrive%\Program Files\ant +goto checkJava + +:checkSystemDrive +rem check for ant in root directory of system drive +if not exist "%SystemDrive%\ant" goto noAntHome +set ANT_HOME=%SystemDrive%\ant +goto checkJava + +:noAntHome +echo ANT_HOME is not set and ant could not be located. Please set ANT_HOME. +goto end + +:checkJava +set _JAVACMD=%JAVACMD% +set LOCALCLASSPATH="%CLASSPATH%" +for %%i in ("%ANT_HOME%\lib\*.jar") do call "%ANT_HOME%\bin\lcp.bat" "%%i" + +if "%JAVA_HOME%" == "" goto noJavaHome +if "%_JAVACMD%" == "" set _JAVACMD=%JAVA_HOME%\bin\java +if exist "%JAVA_HOME%\lib\tools.jar" call "%ANT_HOME%\bin\lcp.bat" "%JAVA_HOME%\lib\tools.jar" +if exist "%JAVA_HOME%\lib\classes.zip" call "%ANT_HOME%\bin\lcp.bat" "%JAVA_HOME%\lib\classes.zip" +goto checkJikes + +:noJavaHome +if "%_JAVACMD%" == "" set _JAVACMD=java +echo. +echo Warning: JAVA_HOME environment variable is not set. +echo If build fails because sun.* classes could not be found +echo you will need to set the JAVA_HOME environment variable +echo to the installation directory of java. +echo. + +:checkJikes +if not "%JIKESPATH%" == "" goto runAntWithJikes + +:runAnt +%_JAVACMD% -classpath %LOCALCLASSPATH% -Dant.home="%ANT_HOME%" %ANT_OPTS% org.apache.tools.ant.Main %ANT_CMD_LINE_ARGS% +goto end + +:runAntWithJikes +%_JAVACMD% -classpath %LOCALCLASSPATH% -Dant.home="%ANT_HOME%" -Djikes.class.path=%JIKESPATH% %ANT_OPTS% org.apache.tools.ant.Main %ANT_CMD_LINE_ARGS% + +:end +set LOCALCLASSPATH= +set _JAVACMD= +set ANT_CMD_LINE_ARGS= + +if not "%OS%"=="Windows_NT" goto mainEnd +:winNTend +@endlocal + +:mainEnd +if exist "%HOME%\antrc_post.bat" call "%HOME%\antrc_post.bat" + diff --git a/tools/bin/antRun b/tools/bin/antRun new file mode 100755 index 0000000000..f0a18f1653 --- /dev/null +++ b/tools/bin/antRun @@ -0,0 +1,9 @@ +#! /bin/sh + +# Args: DIR command +cd "$1" +CMD="$2" +shift +shift + +exec $CMD "$@" diff --git a/tools/bin/antRun.bat b/tools/bin/antRun.bat new file mode 100755 index 0000000000..a5484d692b --- /dev/null +++ b/tools/bin/antRun.bat @@ -0,0 +1,20 @@ +@echo off + +# Change drive and directory to %1 (Win9X only for NT/2K use "cd /d") +cd %1 +%1\ +set ANT_RUN_CMD=%2 +shift +shift + +set PARAMS= +:loop +if ""%1 == "" goto runCommand +set PARAMS=%PARAMS% %1 +shift +goto loop + +:runCommand +rem echo %ANT_RUN_CMD% %PARAMS% +%ANT_RUN_CMD% %PARAMS% + diff --git a/tools/bin/fix-packages.py b/tools/bin/fix-packages.py new file mode 100755 index 0000000000..5858c77a7e --- /dev/null +++ b/tools/bin/fix-packages.py @@ -0,0 +1,216 @@ +#! /usr/bin/env python +# +# Mass string translation for java/xml files (change Wanted re for other files) +# +# Author: Peter Donald +# +# Adapted from fixid.py in python distribution under Tools +# + +import sys +import re +import string +import os +from stat import * +import getopt + +err = sys.stderr.write +dbg = err +out = sys.stdout.write + +def usage(): + progname = sys.argv[0] + err('Usage: ' + progname + ' [-s file] ... file-or-directory ...\n') + err('\n') + err('-s substfile : add a file of substitutions\n') + err('\n') + err('Each non-empty non-comment line in a substitution file must\n') + err('contain exactly two words separated by a | character.\n') + +def main(): + try: + opts, args = getopt.getopt(sys.argv[1:], 'crs:') + except getopt.error, msg: + err('Options error: ' + str(msg) + '\n') + usage() + sys.exit(2) + bad = 0 + if not args: # No arguments + usage() + sys.exit(2) + for opt, arg in opts: + if opt == '-s': + addsubst(arg) + initre() + for arg in args: + if os.path.isdir(arg): + if recursedown(arg): bad = 1 + elif os.path.islink(arg): + err(arg + ': will not process symbolic links\n') + bad = 1 + else: + if fix(arg): bad = 1 + sys.exit(bad) + +# Change this regular expression to select a different set of files +Wanted = '^[a-zA-Z0-9_\-]+\.(java|xml|xinfo)$' +def wanted(name): + return None <> re.match(Wanted, name) + +def recursedown(dirname): + dbg('recursedown(' + `dirname` + ')\n') + bad = 0 + try: + names = os.listdir(dirname) + except os.error, msg: + err(dirname + ': cannot list directory: ' + str(msg) + '\n') + return 1 + names.sort() + subdirs = [] + for name in names: + if name in (os.curdir, os.pardir): continue + fullname = os.path.join(dirname, name) + if os.path.islink(fullname): pass + elif os.path.isdir(fullname): + subdirs.append(fullname) + elif wanted(name): + if fix(fullname): bad = 1 + for fullname in subdirs: + if recursedown(fullname): bad = 1 + return bad + +def fix(filename): + dbg('fix(' + `filename` + ')\n') + + # File replacement mode + try: + f = open(filename, 'r') + except IOError, msg: + err(filename + ': cannot open: ' + str(msg) + '\n') + return 1 + + head, tail = os.path.split(filename) + tempname = os.path.join(head, '@' + tail) + + # If we find a match, we rewind the file and start over but + # now copy everything to a temp file. + lineno = 0 + g = None + while 1: + line = f.readline() + if not line: break + lineno = lineno + 1 + newline = fixline(line) + if newline != line: + if g is None: + try: + g = open(tempname, 'w') + except IOError, msg: + f.close() + err(tempname+': cannot create: '+ + str(msg)+'\n') + return 1 + f.seek(0) + lineno = 0 + out(filename + ':\n') + continue # restart from the beginning + out(`lineno` + '\n') + out('< ' + line) + out('> ' + newline) + if g is not None: + g.write(newline) + + # End of file + f.close() + if not g: return 0 # No changes + + # Finishing touch -- move files + + # First copy the file's mode to the temp file + try: + statbuf = os.stat(filename) + os.chmod(tempname, statbuf[ST_MODE] & 07777) + except os.error, msg: + err(tempname + ': warning: chmod failed (' + str(msg) + ')\n') + + # Then make a backup of the original file as filename~ + try: + os.rename(filename, filename + '~') + except os.error, msg: + err(filename + ': warning: backup failed (' + str(msg) + ')\n') + + # Now move the temp file to the original file + try: + os.rename(tempname, filename) + except os.error, msg: + err(filename + ': rename failed (' + str(msg) + ')\n') + return 1 + + # Return succes + return 0 + +def initre(): + global SearcherExpr + + keys = Dict.keys() + keyCount = len(keys) + i = 0 + reStr = "" + while i < len(keys): + if i != 0: reStr = reStr + '|' + reStr = reStr + keys[i] + i = i + 1 + SearcherExpr = re.compile( reStr ) + +def fixline(line): + global Program +## print '-->', `line` + i = 0 + + while i < len(line): + match = SearcherExpr.search(line, i) + if match == None: break + found = match.group(0) + i = match.start() + n = len(found) + if Dict.has_key(found): + subst = Dict[found] + + line = line[:i] + subst + line[i+n:] + n = len(subst) + i = i + n + return line + +Dict = {} +NotInComment = {} + +def addsubst(substfile): + try: + fp = open(substfile, 'r') + except IOError, msg: + err(substfile + ': cannot read substfile: ' + str(msg) + '\n') + sys.exit(1) + lineno = 0 + + while 1: + line = fp.readline() + if not line: break + lineno = lineno + 1 + try: + i = string.index(line, '#') + except string.index_error: + i = -1 # Happens to delete trailing \n + words = string.split(line[:i],'|') + if not words: continue + if len(words) <> 2: + err(substfile + ':' + `lineno` + ': warning: bad line: ' + line) + continue + [key, value] = words + +## print 'Will replace ', key, ' with ', value + + Dict[key] = value + + fp.close() + +main() diff --git a/tools/bin/lcp.bat b/tools/bin/lcp.bat new file mode 100755 index 0000000000..8d6b8515ab --- /dev/null +++ b/tools/bin/lcp.bat @@ -0,0 +1,2 @@ +set LOCALCLASSPATH=%1;%LOCALCLASSPATH% + diff --git a/tools/bin/runant.pl b/tools/bin/runant.pl new file mode 100755 index 0000000000..a2cc523e71 --- /dev/null +++ b/tools/bin/runant.pl @@ -0,0 +1,131 @@ +#!/usr/bin/perl +####################################################################### +# +# runant.pl +# +# wrapper script for invoking ant in a platform with Perl installed +# this may include cgi-bin invocation, which is considered somewhat daft. +# (slo: that should be a separate file which can be derived from this +# and returns the XML formatted output) +# +# the code is not totally portable due to classpath and directory splitting +# issues. oops. (NB, use File::Spec::Functions will help and the code is +# structured for the catfile() call, but because of perl version funnies +# the code is not included. +# +# created: 2000-8-24 +# last modified: 2000-8-24 +# author: Steve Loughran steve_l@sourceforge.net +####################################################################### +# +# Assumptions: +# +# - the "java" executable/script is on the command path +# - ANT_HOME has been set +# - target platform uses ":" as classpath separator or perl indicates it is dos/win32 +# - target platform uses "/" as directory separator. + +#be fussy about variables +use strict; + +#platform specifics (disabled) +#use File::Spec::Functions; + +#turn warnings on during dev; generates a few spurious uninitialised var access warnings +#use warnings; + +#and set $debug to 1 to turn on trace info +my $debug=0; + +####################################################################### +# +# check to make sure environment is setup +# + +my $HOME = $ENV{ANT_HOME}; +if ($HOME eq "") + { + die "\n\nANT_HOME *MUST* be set!\n\n"; + } + +my $JAVACMD = $ENV{JAVACMD}; +$JAVACMD = "java" if $JAVACMD eq ""; + +#ISSUE: what java wants to split up classpath varies from platform to platform +#and perl is not too hot at hinting which box it is on. +#here I assume ":" 'cept on win32 and dos. Add extra tests here as needed. +my $s=":"; +if(($^O eq "MSWin32") || ($^O eq "dos")) + { + $s=";"; + } + +#build up standard classpath +my $localpath=$ENV{CLASSPATH}; +if ($localpath eq "") + { + print "warning: no initial classpath\n" if ($debug); + $localpath=""; + } + +#add jar files. I am sure there is a perl one liner to do this. +my $jarpattern="$HOME/lib/*.jar"; +my @jarfiles =glob($jarpattern); +print "jarfiles=@jarfiles\n" if ($debug); +my $jar; +foreach $jar (@jarfiles ) + { + $localpath.="$s$jar"; + } + +#if Java home is defined, look for tools.jar & classes.zip and add to classpath +my $JAVA_HOME = $ENV{JAVA_HOME}; +if ($JAVA_HOME ne "") + { + my $tools="$JAVA_HOME/lib/tools.jar"; + if (-e "$tools") + { + $localpath .= "$s$tools"; + } + my $classes="$JAVA_HOME/lib/classes.zip"; + if (-e $classes) + { + $localpath .= "$s$classes"; + } + } +else + { + print "\n\nWarning: JAVA_HOME environment variable is not set.\n". + "If the build fails because sun.* classes could not be found\n". + "you will need to set the JAVA_HOME environment variable\n". + "to the installation directory of java\n"; + } + +#jikes +my @ANT_OPTS=split $ENV{ANT_OPTS}; +if($ENV{JIKESPATH} ne "") + { + push @ANT_OPTS, "-Djikes.class.path=$ENV{JIKESPATH}"; + } + +#construct arguments to java + +my @ARGS; +push @ARGS, "-classpath", "$localpath", "-Dant.home=$HOME"; +push @ARGS, @ANT_OPTS; +push @ARGS, "org.apache.tools.ant.Main"; +push @ARGS, @ARGV; + +print "\n $JAVACMD @ARGS\n\n" if ($debug); + +my $returnValue = system $JAVACMD, @ARGS; +if ($returnValue eq 0) + { + exit 0; + } +else + { + # only 0 and 1 are widely recognized as exit values + # so change the exit value to 1 + exit 1; + } diff --git a/tools/lib/.cvsignore b/tools/lib/.cvsignore new file mode 100755 index 0000000000..eb1aa67684 --- /dev/null +++ b/tools/lib/.cvsignore @@ -0,0 +1,3 @@ +xalan-2.2.0-D14.jar +xerces-1.4.4.jar +xml-apis.jar diff --git a/tools/lib/ant-1.4.1-optional.jar b/tools/lib/ant-1.4.1-optional.jar new file mode 100755 index 0000000000..d6a4b4b627 Binary files /dev/null and b/tools/lib/ant-1.4.1-optional.jar differ diff --git a/tools/lib/ant-1.4.1.jar b/tools/lib/ant-1.4.1.jar new file mode 100755 index 0000000000..8ad84e3480 Binary files /dev/null and b/tools/lib/ant-1.4.1.jar differ diff --git a/tools/lib/jtidy-04aug2000r7-dev.jar b/tools/lib/jtidy-04aug2000r7-dev.jar new file mode 100644 index 0000000000..a11dfe58ac Binary files /dev/null and b/tools/lib/jtidy-04aug2000r7-dev.jar differ diff --git a/tools/lib/junit.jar b/tools/lib/junit.jar new file mode 100755 index 0000000000..914a5cfa9b Binary files /dev/null and b/tools/lib/junit.jar differ diff --git a/tools/lib/xalan-2.2.0.jar b/tools/lib/xalan-2.2.0.jar new file mode 100644 index 0000000000..8dd6dca254 Binary files /dev/null and b/tools/lib/xalan-2.2.0.jar differ diff --git a/tools/resources/Release-Checklist.txt b/tools/resources/Release-Checklist.txt new file mode 100755 index 0000000000..61ebae5824 --- /dev/null +++ b/tools/resources/Release-Checklist.txt @@ -0,0 +1,18 @@ +- build distributions +- sign distributions +- Generate announcements and HEADER.html +- upload distributions to correct dir +- tag CVS +- generate www pages and upload +- bump release ID +- send announcements to announcement@apache.org, announcements@xml.apache.org, announcements@jakarta.apache.org +- news to newsgroups: comp.lang.java.softwaretools +- post stories on + *) jakarta news page + *) theserverside.com + *) freshmeat.net + *) www.javaworld.com + *) www.javalobby.com + *) www.jguru.com + *) www.slashdot.org + (and follow them up) diff --git a/tools/resources/jindent/poi.jin b/tools/resources/jindent/poi.jin new file mode 100755 index 0000000000..5b612fe38a --- /dev/null +++ b/tools/resources/jindent/poi.jin @@ -0,0 +1,319 @@ +### +### Jindent 3.2x property file -- http://www.jindent.de +### +### this encapsulates my preferred style, plus project-specific style ... +### +### author: Marc Johnson +### + +### General -- Convention + +conventionName = "" +conventionString = "" +conventionNotePosition = "none" +blankLinesToSeparateConventionNote = 2 + +### General -- Jindent Note + +jindentNotePosition = "none" +blankLinesToSeparateJindentNote = 2 + +### Header/Footer -- Header Template + +headerSmartMode = infinite +headerIdentifyKey = "Copyright (c) 2002 The Apache Software Foundation" +blankLinesBeforeHeader = 1 +header[00]="/* ====================================================================" +header[01]=" * The Apache Software License, Version 1.1" +header[02]=" *" +header[03]=" * Copyright (c) 2002 The Apache Software Foundation. All rights" +header[04]=" * reserved." +header[05]=" *" +header[06]=" * Redistribution and use in source and binary forms, with or without" +header[07]=" * modification, are permitted provided that the following conditions" +header[08]=" * are met:" +header[09]=" *" +header[10]=" * 1. Redistributions of source code must retain the above copyright" +header[11]=" * notice, this list of conditions and the following disclaimer." +header[12]=" *" +header[13]=" * 2. Redistributions in binary form must reproduce the above copyright" +header[14]=" * notice, this list of conditions and the following disclaimer in" +header[15]=" * the documentation and/or other materials provided with the" +header[16]=" * distribution." +header[17]=" *" +header[18]=" * 3. The end-user documentation included with the redistribution," +header[19]=" * if any, must include the following acknowledgment:" +header[20]=" * "This product includes software developed by the" +header[21]=" * Apache Software Foundation (http://www.apache.org/)."" +header[22]=" * Alternately, this acknowledgment may appear in the software itself," +header[23]=" * if and wherever such third-party acknowledgments normally appear." +header[24]=" *" +header[25]=" * 4. The names "Apache" and "Apache Software Foundation" and" +header[26]=" * "Apache POI" must not be used to endorse or promote products" +header[27]=" * derived from this software without prior written permission. For" +header[28]=" * written permission, please contact apache@apache.org." +header[29]=" *" +header[30]=" * 5. Products derived from this software may not be called "Apache"," +header[31]=" * "Apache POI", nor may "Apache" appear in their name, without" +header[32]=" * prior written permission of the Apache Software Foundation." +header[33]=" *" +header[34]=" * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED" +header[35]=" * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES" +header[36]=" * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE" +header[37]=" * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR" +header[38]=" * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL," +header[39]=" * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT" +header[40]=" * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF" +header[41]=" * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND" +header[42]=" * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY," +header[43]=" * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT" +header[44]=" * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF" +header[45]=" * SUCH DAMAGE." +header[46]=" * ====================================================================" +header[47]=" *" +header[48]=" * This software consists of voluntary contributions made by many" +header[49]=" * individuals on behalf of the Apache Software Foundation. For more" +header[50]=" * information on the Apache Software Foundation, please see" +header[51]=" * ." +header[52]=" */" +blankLinesAfterHeader = 1 + +### Header/Footer -- Footer Template + +footerSmartMode = infinite +footerIdentifyKey = "" +blankLinesBeforeFooter = 0 +footer[00] = "" +blankLinesAfterFooter = 0 + +### Indentation -- Misc + +tabulatorSize = 8 +indentSize = 4 +firstLevelIndent = 0 +indentCaseFromSwitch = true +labelNewLine = true +indentLabels = true +minimumCommentIndent = 3 +indentLeadingsByTabs = false +indentCommentsByTabs = false +indentDeclarationsByTabs = false +indentAssignmentsByTabs = false + +### Indentation -- Alignment + +alignComments = true +alignDeclarations = true +alignAssignments = true +alignTernaryConditions = false +alignTernaryExpressions = true +alignTooLongComments = true + +### Braces -- Style + +leftBraceNewLineGeneral = true +rightBraceNewLineGeneral = true +indentLeftBraceGeneral = 0 +indentRightBraceGeneral = 0 +indentAfterRightBraceGeneral = 0 +cuddleEmptyBracesGeneral = false +indentCuddledBracesGeneral = 0 + +leftBraceNewLineClassInterface = true +rightBraceNewLineClassInterface = true +indentLeftBraceClassInterface = 0 +indentRightBraceClassInterface = 0 +indentAfterRightBraceClassInterface = 0 +cuddleEmptyBracesClassInterface = false +indentCuddledBracesClassInterface = 0 + +leftBraceNewLineMethod = true +rightBraceNewLineMethod = true +indentLeftBraceMethod = 0 +indentRightBraceMethod = 0 +indentAfterRightBraceMethod = 0 +cuddleEmptyBracesMethod = false +indentCuddledBracesMethod = 0 + +leftBraceNewLineTryCatch = true +rightBraceNewLineTryCatch = true +indentLeftBraceTryCatch = 0 +indentRightBraceTryCatch = 0 +indentAfterRightBraceTryCatch = 0 +cuddleEmptyBracesTryCatch = false +indentCuddledBracesTryCatch = 0 + +### Braces -- Insert At + +insertBracesAtIfElse = true +insertBracesAtFor = true +insertBracesAtWhile = true +insertBracesAtDoWhile = true +insertParenthesisAtConditions = true + +### Braces -- If-Else + +singleIfStatementInOneLine = false +singleElseStatementInOneLine = false +specialElseIfTreatment = true + +### JavaDoc -- Misc + +deleteJavaDocComments = false +formatJavaDocComments = true +insertMissingJavaDocTags = true +deleteObsoleteJavaDocTags = false +createPublicClassInterfaceJavaDocs = true +createFriendlyClassInterfaceJavaDocs = false +createPrivateClassInterfaceJavaDocs = false +createProtectedClassInterfaceJavaDocs = false +createPublicMethodJavaDocs = false +createFriendlyMethodJavaDocs = false +createPrivateMethodJavaDocs = false +createProtectedMethodJavaDocs = false +createPublicFieldJavaDocs = false +createFriendlyFieldJavaDocs = false +createPrivateFieldJavaDocs = false +createProtectedFieldJavaDocs = false + +### JavaDoc -- Templates + +sortExceptionsInTemplates = true +javaDocMethodTop[00] = "/**" +javaDocMethodTop[01] = " * Method $objectName$" +javaDocMethodTop[02] = " *" +javaDocMethodParamSeparator[00] = " *" +javaDocMethodParam[00] = " * @param $paramName$" +javaDocMethodReturn[00] = " *" +javaDocMethodReturn[01] = " * @return" +javaDocMethodExceptionSeparator[00] = " *" +javaDocMethodException[00] = " * @exception $exceptionName$" +javaDocMethodBottom[00] = " *" +javaDocMethodBottom[01] = " */" +javaDocConstructorTop[00] = "/**" +javaDocConstructorTop[01] = " * Constructor $objectName$" +javaDocConstructorTop[02] = " *" +javaDocConstructorParamSeparator[00] = " *" +javaDocConstructorParam[00] = " * @param $paramName$" +javaDocConstructorExceptionSeparator[00] = " *" +javaDocConstructorException[00] = " * @exception $exceptionName$" +javaDocConstructorBottom[00] = " *" +javaDocConstructorBottom[01] = " */" +javaDocClass[00] = "/**" +javaDocClass[01] = " * Class $objectName$" +javaDocClass[02] = " *" +javaDocClass[03] = " *" +javaDocClass[04] = " * @author" +javaDocClass[05] = " * @version %I%, %G%" +javaDocClass[06] = " */" +javaDocInterface[00] = "/**" +javaDocInterface[01] = " * Interface $objectName$" +javaDocInterface[02] = " *" +javaDocInterface[03] = " *" +javaDocInterface[04] = " * @author" +javaDocInterface[05] = " * @version %I%, %G%" +javaDocInterface[06] = " */" +javaDocField[00] = "/** Field $objectName$ */" + +### Comments -- Format/Delete + +deleteBlockComments = false +deleteSingleLineComments = false +deleteTrailingComments = false +deleteEndOfLineComments = false +formatBlockComments = true +formatSingleLineComments = true +formatTrailingComments = true +formatEndOfLineComments = true + +### Comments -- Exceptions + +neverIndentFirstColumnComments = true +neverFormatFirstColumnComments = true +neverFormatHeader = false +neverFormatFooter = false + +### Separation -- Misc + +keepBlankLines = 0 +minLinesToInsertBlankLineInClasses = infinite +minLinesToInsertBlankLineInMethods = infinite + +### Separation -- Separate + +separateChunksByComments = false +allowBreakSeparatedFromCaseBlock = false +blankLinesBetweenCaseBlocks = 1 +blankLinesBetweenChunks = 0 +comparableImportDepth = 2 +blankLinesToSeparateImports = 1 +blankLinesBetweenClassInterface = 2 + +### Separation -- Insert Blank Lines + +blankLinesAfterDeclarations = 1 +blankLinesAfterMethods = 1 +blankLinesAfterClasses = 1 +blankLinesAfterInterfaces = 1 +blankLinesBeforeJavaDocComments = 1 +blankLinesAfterJavaDocComments = 1 +blankLinesBeforeBlockComments = 1 +blankLinesAfterBlockComments = 0 +blankLinesBeforeSingleLineComments = 1 +blankLinesAfterSingleLineComments = 0 +blankLinesBeforeEndOfLineComments = 1 +blankLinesAfterEndOfLineComments = 0 +blankLinesAfterSwitch = 1 +blankLinesAfterPackage = 1 +blankLinesAfterLastImport = 1 + +### Whitespaces -- Padding + +separateAssignmentOperators = true +separateConditionalOperators = true +separateComparisonOperators = true +separateNumericalOperators = true +paddingCastParenthesis = true +paddingParenthesis = false +paddingBrackets = true +paddingBraces = true + +### Whitespaces -- Space Before + +spaceBeforeMethodDeclarationParenthesis = false +spaceBeforeMethodCallParenthesis = false +spaceBeforeBrackets = false +spaceBeforeBracketsInTypes = true +spaceBeforeStatementParenthesis = true +spaceBeforeConditionBang = true +spaceBeforeCaseColon = true + +### Whitespaces -- Space After + +spaceAfterComma = true +spaceAfterSemicolon = true +spaceAfterCasting = true + +### Whitespaces -- No Spaces + +noSpacesInEmptyForExpressions = true + +### Line Wrapping -- Misc + +maxFieldElementsPerLine = 0 +wrapLines = true +wrapBecauseOfComments = true +wrapLongMethodNames = true +maxLineLength = 78 +deepIndent = 45 +forceIndent = 8 +forceIndentTolerance = 4 +allowWrappingAfterAssignments = true +allowWrappingAfterParenthesis = true +preferWrappingAfterThrows = true +alwaysWrapThrows = true +alwaysWrapExtends = true +alwaysWrapImplements = true +indentWrappedThrows = 4 +indentWrappedExtends = 4 +indentWrappedImplements = 4 diff --git a/tools/resources/stylesheets/html2xml.xsl b/tools/resources/stylesheets/html2xml.xsl new file mode 100755 index 0000000000..a40bdd2485 --- /dev/null +++ b/tools/resources/stylesheets/html2xml.xsl @@ -0,0 +1,153 @@ + + + + bodyroot + + + + ]]> + + + + + + + + +
+ <xsl:value-of select="title" /><xsl:value-of select="TITLE" /> + + + +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+ +

+
+
+
+ + + + + + + + + + + + + + + + + +
    + +
+
+ + +
  • + +
  • +
    + + +
      + +
    +
    + + + + + + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    diff --git a/tools/src/ClassAvailable.java b/tools/src/ClassAvailable.java new file mode 100644 index 0000000000..bec059aeb1 --- /dev/null +++ b/tools/src/ClassAvailable.java @@ -0,0 +1,246 @@ + +/* ==================================================================== + * The Apache Software License, Version 1.1 + * + * Copyright (c) 2002 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 acknowledgment: + * "This product includes software developed by the + * Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, + * if and wherever such third-party acknowledgments normally appear. + * + * 4. The names "Apache" and "Apache Software Foundation" and + * "Apache POI" must not be used to endorse or promote products + * derived from this software without prior written permission. For + * written permission, please contact apache@apache.org. + * + * 5. Products derived from this software may not be called "Apache", + * "Apache POI", nor may "Apache" appear in their name, without + * prior written permission of the Apache Software Foundation. + * + * 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 + * . + */ + +import java.io.*; + +import java.util.*; +import java.util.zip.*; + +import org.apache.tools.ant.*; +import org.apache.tools.ant.taskdefs.*; +import org.apache.tools.ant.types.*; + +/** + * Will set the given property if the requested class is available in the + * specified classpath. The found class is not loaded! + * This class is heavily based on the available task in the ant package: + * @author Stefano Mazzocchi stefano@apache.org + * + * This task searches only in the defined path but not in the parents path + * unless explicitly overridden by the value of ${build.sysclasspath} + * like the original available task does. + * @author Carsten Ziegeler + * @version CVS $Revision$ $Date$ + */ + +public class ClassAvailable + extends Task +{ + + /** + * A hashtable of zip files opened by the classloader + */ + + private Hashtable zipFiles = new Hashtable(); + private String property; + private String classname; + private Path classpath; + private String value = "true"; + + public void setClasspath(Path classpath) + { + createClasspath().append(classpath); + } + + public Path createClasspath() + { + if (this.classpath == null) + { + this.classpath = new Path(this.project); + } + return this.classpath.createPath(); + } + + public void setClasspathRef(Reference r) + { + createClasspath().setRefid(r); + } + + public void setProperty(String property) + { + this.property = property; + } + + public void setValue(String value) + { + this.value = value; + } + + public void setClassname(String classname) + { + if (!"".equals(classname)) + { + this.classname = classname; + } + } + + public void execute() + throws BuildException + { + if (property == null) + { + throw new BuildException("property attribute is required", + location); + } + if (eval()) + { + this.project.setProperty(property, value); + } + } + + public boolean eval() + throws BuildException + { + if (classname == null) + { + throw new BuildException( + "At least one of (classname|file|resource) is required", + location); + } + if (classpath != null) + { + classpath.setProject(project); + classpath = classpath.concatSystemClasspath("ignore"); + } + if (!findClassInComponents(classname)) + { + log("Unable to load class " + classname + " to set property " + + property, Project.MSG_VERBOSE); + return false; + } + return true; + } + + /** + * Get an inputstream to a given resource in the given file which may + * either be a directory or a zip file. + * + * @param file the file (directory or jar) in which to search for the resource. + * @param resourceName the name of the resource for which a stream is required. + * + * @return a stream to the required resource or null if the resource cannot be + * found in the given file object + */ + + private boolean contains(File file, String resourceName) + { + try + { + if (!file.exists()) + { + return false; + } + if (file.isDirectory()) + { + File resource = new File(file, resourceName); + + if (resource.exists()) + { + return true; + } + } + else + { + + // is the zip file in the cache + ZipFile zipFile = ( ZipFile ) zipFiles.get(file); + + if (zipFile == null) + { + zipFile = new ZipFile(file); + zipFiles.put(file, zipFile); + } + ZipEntry entry = zipFile.getEntry(resourceName); + + if (entry != null) + { + return true; + } + } + } + catch (Exception e) + { + log("Ignoring Exception " + e.getClass().getName() + ": " + + e.getMessage() + " reading resource " + resourceName + + " from " + file, Project.MSG_VERBOSE); + } + return false; + } + + /** + * Find a class on the given classpath. + */ + + private boolean findClassInComponents(String name) + { + + // we need to search the components of the path to see if we can find the + // class we want. + final String classname = name.replace('.', '/') + ".class"; + final String[] list = classpath.list(); + boolean found = false; + int i = 0; + + while ((i < list.length) && (found == false)) + { + final File pathComponent = + ( File ) project.resolveFile(list[ i ]); + + found = this.contains(pathComponent, classname); + i++; + } + return found; + } +} diff --git a/tools/src/JTidyTask.java b/tools/src/JTidyTask.java new file mode 100644 index 0000000000..ce8f5b3af4 --- /dev/null +++ b/tools/src/JTidyTask.java @@ -0,0 +1,272 @@ + +/* ==================================================================== + * The Apache Software License, Version 1.1 + * + * Copyright (c) 2002 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 acknowledgment: + * "This product includes software developed by the + * Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, + * if and wherever such third-party acknowledgments normally appear. + * + * 4. The names "Apache" and "Apache Software Foundation" and + * "Apache POI" must not be used to endorse or promote products + * derived from this software without prior written permission. For + * written permission, please contact apache@apache.org. + * + * 5. Products derived from this software may not be called "Apache", + * "Apache POI", nor may "Apache" appear in their name, without + * prior written permission of the Apache Software Foundation. + * + * 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 + * . + */ + +import java.io.InputStream; +import java.io.FileInputStream; +import java.io.BufferedInputStream; +import java.io.OutputStream; +import java.io.FileOutputStream; +import java.io.Writer; +import java.io.PrintWriter; +import java.io.FileWriter; +import java.io.BufferedWriter; +import java.io.FileWriter; +import java.io.IOException; + +import java.util.ArrayList; + +import org.w3c.dom.NodeList; +import org.w3c.dom.Node; +import org.w3c.dom.Element; +import org.w3c.dom.Attr; +import org.w3c.dom.Document; +import org.w3c.dom.NamedNodeMap; +import org.w3c.tidy.Tidy; + +import org.apache.tools.ant.BuildException; +import org.apache.tools.ant.taskdefs.Property; + +/** + * Task to ask property values to the user. Uses current value as default. + * + * @author Nicola Ken Barozzi + * @created 14 January 2002 + */ + +public class JTidyTask + extends org.apache.tools.ant.Task +{ + private String src; + private String dest; + private String log; + private Tidy tidy; + private String warn = "false"; + private String summary = "false"; + PrintWriter pw; + + /** + * Constructor. + */ + + public JTidyTask() + { + super(); + } + + /** + * Initializes the task. + */ + + public void init() + { + super.init(); + + // Setup an instance of Tidy. + tidy = new Tidy(); + tidy.setXmlOut(true); + tidy.setXHTML(true); + tidy.setDropFontTags(true); + tidy.setLiteralAttribs(true); + tidy.setMakeClean(true); + tidy.setShowWarnings(Boolean.getBoolean(warn)); + tidy.setQuiet(!Boolean.getBoolean(summary)); + } + + /** + * Run the task. + * @exception org.apache.tools.ant.BuildException The exception raised during task execution. + */ + + public void execute() + throws org.apache.tools.ant.BuildException + { + try + { + PrintWriter pw = new PrintWriter(new FileWriter(log)); + + tidy.setErrout(pw); + + // Extract the document using JTidy and stream it. + BufferedInputStream in = + new BufferedInputStream(new FileInputStream(src)); + + // FileOutputStream out = new FileOutputStream(dest); + PrintWriter out = + new PrintWriter(new FileWriter(dest)); + + // using null as output to get dom so to remove duplicate attributes + org.w3c.dom.Document domDoc = tidy.parseDOM(in, null); + + domDoc.normalize(); + stripDuplicateAttributes(domDoc, null); + org.apache.xml.serialize.OutputFormat format = + new org.apache.xml.serialize.OutputFormat(); + + format.setIndenting(true); + format.setEncoding("ISO-8859-1"); + format.setPreserveSpace(true); + format.setLineSeparator("\n"); + org.apache.xml.serialize.XMLSerializer serializer = + new org.apache.xml.serialize.XMLSerializer(out, format); + + serializer.serialize(domDoc); + out.flush(); + out.close(); + in.close(); + pw.flush(); + pw.close(); + } + catch (IOException ioe) + { + throw new BuildException(ioe); + } + } + + public void setSrc(String src) + { + this.src = src; + } + + public void setDest(String dest) + { + this.dest = dest; + } + + public void setLog(String log) + { + this.log = log; + } + + public void setWarn(String warn) + { + this.warn = warn; + } + + public void setSummary(String summary) + { + this.summary = summary; + } + + // using parent because jtidy dom is bugged, cannot get parent or delete child + public static void stripDuplicateAttributes(Node node, Node parent) + { + + // The output depends on the type of the node + switch (node.getNodeType()) + { + + case Node.DOCUMENT_NODE : + { + Document doc = ( Document ) node; + Node child = doc.getFirstChild(); + + while (child != null) + { + stripDuplicateAttributes(child, node); + child = child.getNextSibling(); + } + break; + } + case Node.ELEMENT_NODE : + { + Element elt = ( Element ) node; + NamedNodeMap attrs = elt.getAttributes(); + ArrayList nodesToRemove = new ArrayList(); + int nodesToRemoveNum = 0; + + for (int i = 0; i < attrs.getLength(); i++) + { + Node a = attrs.item(i); + + for (int j = 0; j < attrs.getLength(); j++) + { + Node b = attrs.item(j); + + // if there are two attributes with same name + if ((i != j) + && (a.getNodeName().equals(b.getNodeName()))) + { + nodesToRemove.add(b); + nodesToRemoveNum++; + } + } + } + for (int i = 0; i < nodesToRemoveNum; i++) + { + org.w3c.dom.Attr nodeToDelete = + ( org.w3c.dom.Attr ) nodesToRemove.get(i); + org.w3c.dom.Element nodeToDeleteParent = + ( org.w3c.dom + .Element ) node; // nodeToDelete.getParentNode(); + + nodeToDeleteParent.removeAttributeNode(nodeToDelete); + } + nodesToRemove.clear(); + Node child = elt.getFirstChild(); + + while (child != null) + { + stripDuplicateAttributes(child, node); + child = child.getNextSibling(); + } + break; + } + default : + + // do nothing + break; + } + } +} diff --git a/tools/src/SitemapTool.java b/tools/src/SitemapTool.java new file mode 100644 index 0000000000..23a5f7caca --- /dev/null +++ b/tools/src/SitemapTool.java @@ -0,0 +1,363 @@ + +/* ==================================================================== + * The Apache Software License, Version 1.1 + * + * Copyright (c) 2002 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 acknowledgment: + * "This product includes software developed by the + * Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, + * if and wherever such third-party acknowledgments normally appear. + * + * 4. The names "Apache" and "Apache Software Foundation" and + * "Apache POI" must not be used to endorse or promote products + * derived from this software without prior written permission. For + * written permission, please contact apache@apache.org. + * + * 5. Products derived from this software may not be called "Apache", + * "Apache POI", nor may "Apache" appear in their name, without + * prior written permission of the Apache Software Foundation. + * + * 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 + * . + */ + +import java.io.*; + +import java.util.*; + +import org.apache.tools.ant.*; +import org.apache.tools.ant.taskdefs.*; +import org.apache.tools.ant.types.*; + +/** + * Add components to the sitemap + * + * @author Carsten Ziegeler + * @version CVS $Revision$ $Date$ + */ + +public final class SitemapTool + extends Task +{ + private String sitemap; + private String directory; + private String extension; + + public void setSitemap(String sitemap) + { + this.sitemap = sitemap; + } + + public void setDirectory(String directory) + { + this.directory = directory; + } + + public void setExtension(String extension) + { + this.extension = extension; + } + + public void execute() + throws BuildException + { + if (this.sitemap == null) + { + throw new BuildException("sitemap attribute is required", + location); + } + if (this.extension == null) + { + throw new BuildException("extension attribute is required", + location); + } + if (this.directory == null) + { + throw new BuildException("directory attribute is required", + location); + } + try + { + + // process recursive + this.process(new File(this.directory), this.extension, + this.sitemap); + } + catch (IOException ioe) + { + throw new BuildException("IOException: " + ioe); + } + } + + /** + * Scan recursive + */ + + private void process(final File directoryFile, final String ext, + final String sitemapLocation) + throws IOException, BuildException + { + final File[] files = directoryFile.listFiles(); + + for (int i = 0; i < files.length; i++) + { + if (files[ i ].isDirectory() == true) + { + this.process(files[ i ], ext, sitemapLocation); + } + else + { + if (files[ i ].getName().endsWith("." + ext) == true) + { + System.out.println("Reading: " + + files[ i ].getAbsolutePath()); + final String data = + this.load(files[ i ].getAbsolutePath()); + + // separate the data by lines + final StringTokenizer st = new StringTokenizer(data); + + while (st.hasMoreElements() == true) + { + + // now get the properties of a line. These are separated by a "|" + final String line = + ( String ) st.nextElement(); + final StringTokenizer prop = + new StringTokenizer(line, "|"); + String category = null; + String componentName = null; + String className = null; + String configuration = null; + String label = null; + String mimeType = null; + + while (prop.hasMoreElements() == true) + { + final String property = + ( String ) prop.nextElement(); + final int pos = property.indexOf(":"); + final String propName = + property.substring(0, pos); + final String propVal = property.substring(pos + + 1); + + if (propName.equals("category")) + { + category = propVal; + } + else if (propName.equals("componentName")) + { + componentName = propVal; + } + else if (propName.equals("componentClass")) + { + className = propVal; + } + else if (propName.equals("configuration")) + { + configuration = propVal; + } + else if (propName.equals("label")) + { + label = propVal; + } + else if (propName.equals("mimeType")) + { + mimeType = propVal; + } + else + { + throw new BuildException( + "Unknown property " + propName + + " in file " + + files[ i ].getAbsolutePath()); + } + } + + // Test for required values + if (category == null) + { + throw new BuildException( + "category property is required in file " + + files[ i ].getAbsolutePath(), location); + } + if (componentName == null) + { + throw new BuildException( + "componentName property is required in file " + + files[ i ].getAbsolutePath(), location); + } + if (className == null) + { + throw new BuildException( + "componentClass property is required in file " + + files[ i ].getAbsolutePath(), location); + } + this.add(sitemapLocation, category, componentName, + className, configuration, label, mimeType); + } + } + } + } + } + + /** + * Add entry to sitemap + */ + + private void add(final String sitemapLocation, final String category, + final String componentName, final String className, + final String configuration, final String label, + final String mimeType) + throws IOException + { + final String data = load(sitemapLocation); + final String searchString = + new StringBuffer("") + .toString(); + final int pos = data.indexOf(searchString); + int categoryStartPos = + data + .indexOf(new StringBuffer("") + .toString()); + + if (categoryStartPos == -1) + { + categoryStartPos = + data + .indexOf(new StringBuffer(" 0)) + { + buffer.append(" mime-type=\"").append(mimeType) + .append("\""); + } + if ((null != label) && (label.length() > 0)) + { + buffer.append(" label=\"").append(label).append("\""); + } + if (null != configuration) + { + buffer.append(">\n").append(configuration).append("\n") + .append("\n"); + } + else + { + buffer.append("/>\n"); + } + buffer.append(data.substring(pos)).toString(); + this.save(sitemapLocation, buffer.toString()); + } + } + } + + /** + * Load a file and return the content as a string. + */ + + public String load(String filename) + throws IOException + { + FileInputStream fis; + + fis = new FileInputStream(filename); + int available; + byte[] data = null; + byte[] tempData; + byte[] copyData; + + do + { + available = 1024; + tempData = new byte[ available ]; + available = fis.read(tempData, 0, available); + if (available > 0) + { + copyData = new byte[ ((data == null) ? 0 + : data.length) + available ]; + if (data != null) + { + System.arraycopy(data, 0, copyData, 0, data.length); + } + System.arraycopy(tempData, 0, copyData, ((data == null) ? 0 + : data.length), available); + data = copyData; + } + } + while (available > 0); + fis.close(); + return ((data != null) ? new String(data) + : ""); + } + + /** + * Save the string to a file + */ + + public void save(String filename, String data) + throws IOException + { + FileWriter fw = new FileWriter(filename); + + fw.write(data); + fw.close(); + } +} diff --git a/tools/src/UserInput.java b/tools/src/UserInput.java new file mode 100644 index 0000000000..34a75f0ba8 --- /dev/null +++ b/tools/src/UserInput.java @@ -0,0 +1,151 @@ + +/* ==================================================================== + * The Apache Software License, Version 1.1 + * + * Copyright (c) 2002 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 acknowledgment: + * "This product includes software developed by the + * Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, + * if and wherever such third-party acknowledgments normally appear. + * + * 4. The names "Apache" and "Apache Software Foundation" and + * "Apache POI" must not be used to endorse or promote products + * derived from this software without prior written permission. For + * written permission, please contact apache@apache.org. + * + * 5. Products derived from this software may not be called "Apache", + * "Apache POI", nor may "Apache" appear in their name, without + * prior written permission of the Apache Software Foundation. + * + * 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 + * . + */ + +import java.io.InputStreamReader; +import java.io.BufferedReader; +import java.io.IOException; + +import org.apache.tools.ant.taskdefs.Property; + +/** + * Task to ask property values to the user. Uses current value as default. + * + * @author Nicola Ken Barozzi + * @created 14 January 2002 + */ + +public class UserInput + extends org.apache.tools.ant.Task +{ + private String question; + private String name; + private String value; + + /** + * Constructor. + */ + + public UserInput() + { + super(); + } + + /** + * Initializes the task. + */ + + public void init() + { + super.init(); + question = "?"; + } + + /** + * Run the task. + * @exception org.apache.tools.ant.BuildException The exception raised during task execution. + */ + + public void execute() + throws org.apache.tools.ant.BuildException + { + value = project.getProperty(name); + String defaultvalue = value; + + // if the property exists + if (value != null) + { + System.out.println("\n" + question + " [" + value + "] "); + BufferedReader reader = + new BufferedReader(new InputStreamReader(System.in)); + + try + { + value = reader.readLine(); + } + catch (IOException e) + { + value = defaultvalue; + } + if (!value.equals("")) + { + project.setProperty(name, value); + } + else + { + project.setProperty(name, defaultvalue); + } + } + } + + /** + * Sets the prompt text that will be presented to the user. + * @param prompt String + */ + + public void addText(String question) + { + this.question = question; + } + + public void setQuestion(String question) + { + this.question = question; + } + + public void setName(String name) + { + this.name = name; + } +} diff --git a/tools/src/XConfTool.java b/tools/src/XConfTool.java new file mode 100644 index 0000000000..becdba9215 --- /dev/null +++ b/tools/src/XConfTool.java @@ -0,0 +1,238 @@ + +/* ==================================================================== + * The Apache Software License, Version 1.1 + * + * Copyright (c) 2002 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 acknowledgment: + * "This product includes software developed by the + * Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, + * if and wherever such third-party acknowledgments normally appear. + * + * 4. The names "Apache" and "Apache Software Foundation" and + * "Apache POI" must not be used to endorse or promote products + * derived from this software without prior written permission. For + * written permission, please contact apache@apache.org. + * + * 5. Products derived from this software may not be called "Apache", + * "Apache POI", nor may "Apache" appear in their name, without + * prior written permission of the Apache Software Foundation. + * + * 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 + * . + */ + +import java.io.*; + +import java.util.*; + +import org.apache.tools.ant.*; +import org.apache.tools.ant.taskdefs.*; +import org.apache.tools.ant.types.*; + +/** + * Add components to the cocoon.xconf + * This is only a ugly first shot + * + * @author Carsten Ziegeler + * @version CVS $Revision$ $Date$ + */ + +public final class XConfTool + extends Task +{ + private String configuration; + private String directory; + private String extension; + + public void setConfiguration(String configuration) + { + this.configuration = configuration; + } + + public void setDirectory(String directory) + { + this.directory = directory; + } + + public void setExtension(String extension) + { + this.extension = extension; + } + + public void execute() + throws BuildException + { + if (this.configuration == null) + { + throw new BuildException("configuration attribute is required", + location); + } + if (this.extension == null) + { + throw new BuildException("extension attribute is required", + location); + } + if (this.directory == null) + { + throw new BuildException("directory attribute is required", + location); + } + try + { + + // process recursive + this.process(new File(this.directory), this.extension, + this.configuration); + } + catch (IOException ioe) + { + throw new BuildException("IOException: " + ioe); + } + } + + /** + * Scan recursive + */ + + private void process(final File directoryFile, final String ext, + final String configurationLocation) + throws IOException, BuildException + { + final File[] files = directoryFile.listFiles(); + + for (int i = 0; i < files.length; i++) + { + if (files[ i ].isDirectory() == true) + { + this.process(files[ i ], ext, configurationLocation); + } + else + { + if (files[ i ].getName().endsWith("." + ext) == true) + { + System.out.println("Reading: " + + files[ i ].getAbsolutePath()); + final String newComponent = + this.load(files[ i ].getAbsolutePath()); + + this.add(configurationLocation, newComponent); + } + } + } + } + + /** + * Add entry to sitemap + */ + + private void add(final String configurationLocation, + final String newComponent) + throws IOException + { + final String data = load(configurationLocation); + + // first search if component already present: + if (data.indexOf(newComponent) == -1) + { + int pos = data.indexOf("", pos); + if (pos != -1) + { + StringBuffer buffer = + new StringBuffer(data.substring(0, pos + 1)) + .append("\n\n").append(newComponent) + .append(data.substring(pos + 1)); + + this.save(configurationLocation, buffer.toString()); + } + } + } + } + + /** + * Load a file and return the content as a string. + */ + + public String load(String filename) + throws IOException + { + FileInputStream fis; + + fis = new FileInputStream(filename); + int available; + byte[] data = null; + byte[] tempData; + byte[] copyData; + + do + { + available = 1024; + tempData = new byte[ available ]; + available = fis.read(tempData, 0, available); + if (available > 0) + { + copyData = new byte[ ((data == null) ? 0 + : data.length) + available ]; + if (data != null) + { + System.arraycopy(data, 0, copyData, 0, data.length); + } + System.arraycopy(tempData, 0, copyData, ((data == null) ? 0 + : data.length), available); + data = copyData; + } + } + while (available > 0); + fis.close(); + return ((data != null) ? new String(data) + : ""); + } + + /** + * Save the string to a file + */ + + public void save(String filename, String data) + throws IOException + { + FileWriter fw = new FileWriter(filename); + + fw.write(data); + fw.close(); + } +} diff --git a/tools/src/announcement2header.xsl b/tools/src/announcement2header.xsl new file mode 100755 index 0000000000..c326fa56a7 --- /dev/null +++ b/tools/src/announcement2header.xsl @@ -0,0 +1,78 @@ + + + + + + + + + + + + + +

    Released

    + + + +

    About

    + +
    + +
    + + +

    + +

    For more information about , please go to + + .

    + + + +
    + + +
    + +
    +
    + + +

    +
    + + + + + + +
      + +
    • + + + [] + +
    • +
      +
    +
    + +
    diff --git a/tools/src/announcement2readme.xsl b/tools/src/announcement2readme.xsl new file mode 100755 index 0000000000..63cbdefd07 --- /dev/null +++ b/tools/src/announcement2readme.xsl @@ -0,0 +1,89 @@ + + + + + + + + + + + + + + +

    PGP Signatures

    + +

    Many of the distribution kits have been digitally signed (using + PGP). If so, there will be an accompanying + distribution.asc file in the same directory as + the distribution. The PGP keys can be found in the distribution + directory at < + http://jakarta.apache.org/builds/jakarta-avalon/release/KEYS>.

    + + --bin.tar.gz + +
    Always test available signatures, e.g.,
    +> pgpk -a KEYS
    +> pgpv .asc
    +or,
    +> pgp -ka KEYS
    +> pgp .asc
    +or,
    +> gpg --import KEYS
    +> gpg --verify .asc
    +
    + + + +

    About

    + +
    +
    + +
    + + + +

    For more information about , please go to + + .

    + + + +

    ChangeLog for

    + +
    +
    + + + + + + +
      + +
    • + + + [] + +
    • +
      +
    +
    + +
    diff --git a/tools/src/announcement2site.xsl b/tools/src/announcement2site.xsl new file mode 100755 index 0000000000..52a41cd9c5 --- /dev/null +++ b/tools/src/announcement2site.xsl @@ -0,0 +1,92 @@ + + + + + + + + + var month = new Array ( + "January", + "February", + "March", + "April", + "May", + "June", + "July", + "August", + "September", + "October", + "November", + "December" + ); + + function getdate() + { + var d = new Date(); + var mo = month[d.getMonth()]; + var dy = d.getDate(); + var yr = d.getFullYear(); + var dateString = dy + " " + mo + " " + yr; + return dateString; + } + + + + + + + + + +

    - Released

    + + + +

    About : + +

    +
    + +
    +
    + + + + +

    For more information about , please go to + + .

    + + +
    + + +

    +
    + + + + + + + + + + + + + + +

    +
    + + + + +
    diff --git a/tools/src/announcement2txt.xsl b/tools/src/announcement2txt.xsl new file mode 100755 index 0000000000..9b03cc12b4 --- /dev/null +++ b/tools/src/announcement2txt.xsl @@ -0,0 +1,174 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + Released + + + + + + + + + + + About + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +For more information about + + , please go to + + + + + + + +ChangeLog for + + + + + + + + + + +Downloads for available at + +/latest + + + + + + + + + + + + + ( + + ) + + + + + *) + + + + + + [] + + + + + + + + + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tools/src/bugzilla2patchqueue.xsl b/tools/src/bugzilla2patchqueue.xsl new file mode 100755 index 0000000000..96e91245a4 --- /dev/null +++ b/tools/src/bugzilla2patchqueue.xsl @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + http://nagoya.apache.org/bugzilla/ + + + + + + + + + + + + + + + + + + + diff --git a/tools/src/changelog.xsl b/tools/src/changelog.xsl new file mode 100755 index 0000000000..20f7cf9fb6 --- /dev/null +++ b/tools/src/changelog.xsl @@ -0,0 +1,95 @@ + + + + + + module + cvsweb + + + + + + + + +

    Change Log

    + + + + + + + + +
    + + + +

    + + + +

    +

    + + + by + +

    +

    + +

    +
    + +
    + + + + + + + + + + + + + + +
    + + + /?rev=&content-type=text/x-cvsweb-markup + + + /?r1=&r2=&diff_format=h + + + + +
    + + + + + + + + + +
    + + + + + +
    + + + +
    +
    + +
    + diff --git a/tools/src/patchqueue2text4dev.xsl b/tools/src/patchqueue2text4dev.xsl new file mode 100755 index 0000000000..57986547c9 --- /dev/null +++ b/tools/src/patchqueue2text4dev.xsl @@ -0,0 +1,70 @@ + + + + + + + ----------------------------------------------------------- + This mail is generated automatically using + Jakarta Ant. Contents are automatically + downloaded from Apache's Bugzilla. +----------------------------------------------------------- + Please do not reply to this mail. +----------------------------------------------------------- + +*********************************************************** + __ __ __ __ __ __ + (___ (__) (___ (__) (__) | ) + + __ __ _|_ __ |__ ___ __ + |__) (__( |_, (___ | ) (__/_ __) + | +*********************************************************** +***************** patches in queue: ******************** +*********************************************************** + +----------------------------------------------------------- +: +----------------------------------------------------------- + + +REVIEWER: +RESOLUTION: +STATUS: + + + +*************************that's it!************************ + +------------------------patch HOWTO------------------------ + +Send patches to http://nagoya.apache.org/bugzilla/ +specifying [PATCH] in the summary. +Bugzilla sends a mail automatically to this list. +Reviewers will mark it FIXED there when applied. +Patches not sent to Bugzilla will not be reviewed. +----------------------------------------------------------- +This file is generated and updated automatically at least +once a week, and the data is taken from Bugzilla. +If you don't find the patch you submitted to bugzilla +after one week, please notify cocoon-dev@xml.apache.org +for assistance. +----------------------------------------------------------- +There is usually a HEAD branch and a previous-version +branch that are maintained. Where will the patch go? +1. If it is a bug fix it should go to both branches +2. If something is totally new it goes into HEAD scratchpad. +3. Something in between, but does not break backward + compatibility _may_ go into both (and may not) +4. For everything else, a vote is required so + first it may go into HEAD, and then be VOTEd in order + to sync this into branch. +Please note that structural changes have to be VOTEd first. + + + + + + + diff --git a/tools/src/patchqueue2xdocs.xsl b/tools/src/patchqueue2xdocs.xsl new file mode 100755 index 0000000000..37194957b0 --- /dev/null +++ b/tools/src/patchqueue2xdocs.xsl @@ -0,0 +1,109 @@ + + + + + + + + + + ]]> + + + +
    + Patch Queue + + + + +
    + + + + + +

    + This is an informal list - in chronological order - + of some of the noteworthy patches that have been posted + to the cocoon-dev mailing list. + These patches are not (yet) part of the Apache Cocoon project, but need reviewing for possible + inclusion. This system was instituted because, due to the large volume of mail and + the lack of time of the committers, some patches tended to get forgotten about. This + queue does not guarantee that any patch will be reviewed within a reasonable time frame, + but it does at least make them easier to find! +

    + +

    Reviewers wanted! - If you have time to review and/or test these patches, + we would be grateful for your time. Please post comments to the cocoon-dev mailing lists. +

    + +

    + Before submitting a patch, please read the page on Third-Party + Contributions. The preferred submission method for patches is: +

    + +
      +
    • Post to cocoon-dev@xml.apache.org
    • +
    • Describe the patch, the reason for it and (if necessary) why this is important.
    • +
    • Generate the patch in diff -u format from CVS
    • +
    • Also generate a documentation patch or new file, if this is something that should be documented. +
    • +
    • Post as an attachment rather than inline (unless it is trivially small).
    • +
    + +

    Following the above guidelines will facilitate your patch being reviewed + and applied efficiently.

    + +
    + + + +

    [Under Construction] Archive links will be added later. + Please do not bother the patch submitters/authors without first reading the + relevant post(s) in the mailing list archives. +

    + +

    Vapourware will not be listed.

    + + + + + + + + + + + + + + + + + + +
    idSummaryReviewerResolutionStatus
    + + + + +
    + +

    See also additional list of patches to be added in To Do. +

    + +
    + +
    + +
    + + + + + +
    -- cgit v1.2.3