[BACK]Return to regen.sh CVS log [TXT][DIR] Up to [local] / openbsd / OpenBSDTorrents

Annotation of openbsd/OpenBSDTorrents/regen.sh, Revision 1.6

1.1       andrew      1: #!/bin/sh
1.6     ! andrew      2: #$Id: regen.sh,v 1.5 2005/04/06 21:33:35 andrew Exp andrew $
1.1       andrew      3:
1.5       andrew      4: . /etc/OpenBSDTorrents.conf
1.3       andrew      5:
1.5       andrew      6: cd ${OBT_DIR_HOME}
1.6     ! andrew      7: PIDFILE=${OBT_DIR_HOME}/run/regen.pid
        !             8:
        !             9: if [ -e ${PIDFILE} ]; then
        !            10:         PID=`head -1 ${PIDFILE}`
        !            11:         kill -0 ${PID} 2> /dev/null
        !            12:         if [ $? -eq 0 ]; then
        !            13:                 echo Already running
        !            14:                 exit 1
        !            15:         fi
        !            16: fi
        !            17: echo $$ > ${PIDFILE}
1.3       andrew     18:
                     19: if [[ $1 != skip ]]; then
1.5       andrew     20:        echo ${OBT_DIR_HOME}/MakeTorrents.pl $*
                     21:        ${OBT_DIR_HOME}/MakeTorrents.pl $*
1.3       andrew     22: fi
                     23:
1.5       andrew     24: echo ${OBT_DIR_HOME}/CurrentTorrents.pl
                     25: ${OBT_DIR_HOME}/CurrentTorrents.pl
1.3       andrew     26:
                     27: if [ $? != 253 ]; then
1.5       andrew     28:        echo lftp -f ${OBT_DIR_HOME}/lftp.script
                     29:        lftp -f ${OBT_DIR_HOME}/lftp.script
1.3       andrew     30:
1.5       andrew     31:        echo ${OBT_DIR_HOME}/ServerTorrents.pl
                     32:        ${OBT_DIR_HOME}/ServerTorrents.pl
1.3       andrew     33: fi

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>