scripts/cvsweb/update.sh
pauget fd0b00f93a Be quiet.
darcs-hash:20041206125830-41617-1a1d0c993e700f626dc7efa86b022074d64d422e.gz
2004-12-06 13:58:30 +01:00

19 lines
537 B
Bash
Executable file

#!/bin/sh
# Mise à jour de l'arborescence du site web
# Execute toutes les minutes (par root).
OQP=/var/lock/cvsweb
CHEMIN=/var/local/cvsweb
REPOSITORY=/home/httpd/CVS-Repository/
if [ $CHEMIN/commit.todo -nt $CHEMIN/commit.ok ]; then
if ! [[ -f $OQP ]]; then
chown -R www-data:webcvs $REPOSITORY
chmod -R o-rwx $REPOSITORY
touch $OQP
cd /home/httpd/web
su www-data -c "/usr/bin/cvs -d $REPOSITORY update -P -d" >/dev/null 2>&1
test -s $OQP || rm -f $OQP
su www-data -c "touch $CHEMIN/commit.ok"
fi
fi