1.1 --- a/scripts/server-services/repodoc/make-doc Mon Dec 04 13:13:14 2006 +0000
1.2 +++ b/scripts/server-services/repodoc/make-doc Mon Dec 04 14:29:58 2006 +0000
1.3 @@ -1,48 +1,49 @@
1.4 #!/bin/bash
1.5
1.6 -REPOSITORY=https://lemon.cs.elte.hu/svn/hugo/trunk
1.7 -WORKINGCOPY=trunk
1.8 +(
1.9 + REPOSITORY=https://lemon.cs.elte.hu/svn/hugo/trunk
1.10 + WORKINGCOPY=trunk
1.11
1.12 -ROOT=$PWD
1.13 -LASTREV_FILE=$ROOT/last-rev
1.14 -LASTREV=`cat $LASTREV_FILE`
1.15 -
1.16 -svn up $WORKINGCOPY
1.17 -
1.18 -REV=`svn info $WORKINGCOPY|grep 'Revision:'|cut -f 2 -d ' '`
1.19 -LOGFILE=${ROOT}/logs/${REV}.log
1.20 -
1.21 -function make-dir () {
1.22 - if [ ! -d $1 ]; then
1.23 - mkdir $1
1.24 + ROOT=$PWD
1.25 + LASTREV_FILE=$ROOT/last-rev
1.26 + LASTREV=`cat $LASTREV_FILE`
1.27 +
1.28 + svn up $WORKINGCOPY
1.29 +
1.30 + REV=`svn info $WORKINGCOPY|grep 'Revision:'|cut -f 2 -d ' '`
1.31 + LOGFILE=${ROOT}/logs/${REV}.log
1.32 +
1.33 + function make-dir () {
1.34 + if [ ! -d $1 ]; then
1.35 + mkdir $1
1.36 + fi
1.37 + }
1.38 +
1.39 +
1.40 + if [ $# -eq 0 ]; then
1.41 +# echo $LASTREV $REV
1.42 + if [ $LASTREV -lt $REV ]; then
1.43 + cd $WORKINGCOPY
1.44 + autoreconf -vi
1.45 + ./configure
1.46 + make doc
1.47 + cd ..
1.48 + rm -rf latest-doc
1.49 + cp -r $WORKINGCOPY/doc/html latest-doc
1.50 + echo $REV >$LASTREV_FILE
1.51 + fi
1.52 +
1.53 + elif [ $1 = '--help' ]; then
1.54 + echo 'Usage:'
1.55 + echo ' doxymake --init'
1.56 + echo ' doxymake --help'
1.57 + echo ' doxymake'
1.58 + exit 1
1.59 + elif [ $1 = '--init' ]; then
1.60 + make-dir logs
1.61 + rm -rf $WORKINGCOPY
1.62 + svn co $REPOSITORY $WORKINGCOPY
1.63 + echo '0' >$LASTREV_FILE
1.64 + exit 0
1.65 fi
1.66 -}
1.67 -
1.68 -
1.69 -if [ $# -eq 0 ]; then
1.70 - echo $LASTREV $REV
1.71 - if [ $LASTREV -lt $REV ]; then
1.72 - cd $WORKINGCOPY
1.73 - autoreconf -vi
1.74 - ./configure
1.75 - make doc
1.76 - cd ..
1.77 - rm -rf latest-doc
1.78 - cp -r $WORKINGCOPY/doc/html latest-doc
1.79 - echo $REV >$LASTREV_FILE
1.80 - fi
1.81 -
1.82 -elif [ $1 = '--help' ]; then
1.83 - echo 'Usage:'
1.84 - echo ' doxymake --init'
1.85 - echo ' doxymake --help'
1.86 - echo ' doxymake'
1.87 - exit 1
1.88 -elif [ $1 = '--init' ]; then
1.89 - make-dir logs
1.90 - rm -rf $WORKINGCOPY
1.91 - svn co $REPOSITORY $WORKINGCOPY
1.92 - echo '0' >$LASTREV_FILE
1.93 - exit 0
1.94 -fi
1.95 -
1.96 + ) >/dev/null 2>&1