committed to the main (as opposed to ~wosch/cvs) CVS repository so that committers can modify it without the assistance of (but, of course, with the approval of) the webmaster and/or his lieutenant. It may also serve as a starting point for web site mirrors' update scripts. Requested by: nik Obtained from: freefall:~wosch/bin/myupdate
32 lines
698 B
Bash
32 lines
698 B
Bash
#!/bin/sh
|
|
# Copyright (c) 2001 Wolfram Schneider <wosch@FreeBSD.org>
|
|
#
|
|
# update the FreeBSD Web-Server from the CVS repository
|
|
#
|
|
# $FreeBSD$
|
|
#
|
|
|
|
PATH=/bin:/usr/bin:/usr/local/bin; export PATH
|
|
CVSROOT=/home/ncvs; export CVSROOT
|
|
|
|
build_dir=/usr/local/www/build
|
|
logfile=log.make.`date '+%d'`
|
|
|
|
cd $build_dir || exit 2
|
|
|
|
cvs -qR update -dP www doc > $logfile 2>&1 || exit 2
|
|
|
|
# fresh checkout
|
|
# rm -rf www doc || exit 2
|
|
# cvs -QR co www doc || exit 2
|
|
|
|
cd www || exit 2
|
|
cd en || exit 2
|
|
|
|
# force a rebuild every week at sunday
|
|
case `date '+%u'` in 7) make clean > /dev/null 2>&1 ;; esac
|
|
|
|
time make all > $logfile 2>&1 &&
|
|
time make DESTDIR=/usr/local/www install >> $logfile 2>&1 ||
|
|
tail -50 $logfile
|
|
|