| echo "usage: $0 <working directory>" |
| echo "no such directory '$DIR'" |
| if [ ! -d $DIR/CVS ]; then |
| echo "'$DIR' has no CVS directory!" |
| if [ ! -f $DIR/CVS/Repository ]; then |
| echo "'$DIR' has no CVS/Repository!" |
| if [ ! -f $DIR/CVS/Root ]; then |
| echo "'$DIR' has no CVS/Root!" |
| if [ -f $DIR/CVS/Tag ]; then |
| TAG="-r `cat $DIR/CVS/Tag | cut -c 2-`" |
| REP="`cat $DIR/CVS/Repository`" |
| ROOT="`cat $DIR/CVS/Root`" |
| echo "Directory $DIR is rooted at $ROOT, $TAG $REP..." |
| echo "update with cvs -z3 -d $ROOT -q co $TAG -d $DIR $REP" |