From: <smi...@us...> - 2004-01-01 19:14:15
|
Update of /cvsroot/devil-linux/scripts/webtools In directory sc8-pr-cvs1:/tmp/cvs-serv21772 Modified Files: generate_docs_from_cvs Log Message: working version Index: generate_docs_from_cvs =================================================================== RCS file: /cvsroot/devil-linux/scripts/webtools/generate_docs_from_cvs,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- generate_docs_from_cvs 1 Jan 2004 18:37:32 -0000 1.1 +++ generate_docs_from_cvs 1 Jan 2004 19:14:11 -0000 1.2 @@ -3,18 +3,29 @@ # xml_docs # check out the XML documentation and generate it -# $1 = tag name -# $2 = version string +# $1 = version string +# $2 = tag name (optional) function xml_docs { + echo "generating docs for version $1" test -d build && rm -rf build [ -f ~/.cvspass ] || cvs -d:pserver:ano...@cv...:/cvsroot/devil-linux login || exit 1 echo Getting files from cvs: - cvs -d:pserver:ano...@cv...:/cvsroot/devil-linux co -r $1 build > /dev/null || exit 1 + TAG="" + test -n "$2" && TAG="-r $2" + cvs -q -d:pserver:ano...@cv...:/cvsroot/devil-linux co $TAG build > /dev/null || exit 1 echo Generating HTML - java com.icl.saxon.StyleSheet build/docs/documentation/documentation.xml build/docs/documentation/stylesheets/html.xsl || exit 1 + java -cp $(pwd)/build/docs/documentation/java/saxon.jar com.icl.saxon.StyleSheet build/docs/documentation/documentation.xml build/docs/documentation/stylesheets/html.xsl || exit 1 + + mkdir -p output.html/images/ || exit 1 + cp -dpR build/docs/documentation/stylesheets/images/*.png output.html/images || exit 1 + cp -dpR build/docs/documentation/documentation.css output.html || exit 1 + cp -dpR build/docs/documentation/images/*.png output.html/images || exit 1 + mv output.html docu/$1 || exit 1 + + rm -rf build } cd /home/groups/d/de/devil-linux || exit 1 @@ -22,20 +33,19 @@ test -d docu && rm -rf docu mkdir -p docu || exit 1 -xml_docs rel-1-0-patches 1.0.x - -return -exit 1 +xml_docs 1.0.x rel-1-0-patches +xml_docs 1.1.x echo -n "Cleaning up and updating rights..." -find web/ -type d -name CVS | xargs rm -rf -find web/ -type f | xargs chmod 0664 -find web/ -type d | xargs chmod 2775 +find docu/ -type d -name CVS | xargs rm -rf +find docu/ -type f | xargs chmod 0664 +find docu/ -type d | xargs chmod 2775 echo done. echo -n "Moving new files into place..." -mv htdocs htdocs.old -mv web htdocs -rm -rf htdocs.old +find htdocs/documentation/ -type d | grep -v "documentation/" | xargs rm -rf +mv docu/* htdocs/documentation/ echo done. + +rm -rf docu |