Sophie

Sophie

distrib > Mandriva > 7.2 > i586 > media > main-src > by-pkgid > 3bc4e7f2661a2f5f1e03676f7aa47778 > files > 12

cvs-1.10.8-6mdk.src.rpm

#!/bin/sh
#---------------------------------------------------------------
# Project         : Mandrake
# Module          : cvs
# File            : cvspserver
# Version         : $Id$
# Author          : Frederic Lepied
# Created On      : Tue Mar 28 07:49:39 2000
# Purpose	  : Launch cvs pserver with the right options
# according to /etc/cvs/cvs.conf.
#---------------------------------------------------------------

set -e

CONF=/etc/cvs/cvs.conf

if [ ! -r $CONF ]; then
    echo "No $CONF found" 1>&2
    exit 1
fi

. $CONF

args=""
for d in $CVS_REPOS; do
    if [ -d $d/CVSROOT ]; then
	args="$args --allow-root=$d"
    fi
done

if [ -n "$args" ]; then
    exec /usr/bin/cvs -f $args pserver
else
    echo "no repository configured in $CONF" 1>&2
    exit 2
fi

# cvspserver ends here