]> git.decadent.org.uk Git - dak.git/blob - scripts/debian/update-mirrorlists
daklib/dbconn.py: DBBinary.get_component_name is gone, use PoolFile.component instead
[dak.git] / scripts / debian / update-mirrorlists
1 #!/bin/sh
2 #
3 # Very Very hackish script...  dont laugh.
4 # Michael Beattie <mjb@debian.org>
5
6 export SCRIPTVARS=/srv/ftp-master.debian.org/dak/config/debian/vars
7 . $SCRIPTVARS
8
9 prog=$scriptdir/mirrorlist/mirror_list.pl
10 masterlist=$scriptdir/mirrorlist/Mirrors.masterlist
11
12 test ! -f $HOME/.cvspass && touch $HOME/.cvspass
13
14 grep -q "anonscm.debian.org:/cvs/webwml" ~/.cvspass || \
15         echo ":pserver:anonymous@anonscm.debian.org:/cvs/webwml A" >> $HOME/.cvspass
16
17 cd $(dirname $masterlist)
18 cvs update
19
20 if [ ! -f $ftpdir/README.mirrors.html -o $masterlist -nt $ftpdir/README.mirrors.html ] ; then
21         rm -f $ftpdir/README.mirrors.html $ftpdir/README.mirrors.txt
22         $prog -m $masterlist -t html > $ftpdir/README.mirrors.html
23         $prog -m $masterlist -t text > $ftpdir/README.mirrors.txt
24         echo Updated archive version of mirrors file
25 fi