]> git.decadent.org.uk Git - dak.git/blob - mkmaintainers
Accept .katie as an argument too.
[dak.git] / mkmaintainers
1 #! /bin/sh
2 # $Id: mkmaintainers,v 1.2 2001-09-26 03:47:15 troup Exp $
3
4 echo
5 echo -n 'Creating Maintainers index ... '
6
7 set -e
8 . $SCRIPTVARS
9 cd $masterdir
10
11 nonusmaint="$masterdir/Maintainers_Versions-non-US"
12
13
14 if wget -q -O Maintainers_Versions-non-US.gz http://non-us.debian.org/indices-non-US/Maintainers_Versions.gz; then
15         rm -f $nonusmaint
16         gunzip -c ${nonusmaint}.gz > $nonusmaint
17         rm -f ${nonusmaint}.gz
18 fi
19
20 cd $indices
21 $masterdir/charisma $nonusmaint $masterdir/pseudo-packages.maintainers | sed -e "s/~[^  ]*\([   ]\)/\1/"  | awk '{printf "%-20s ", $1; for (i=2; i<=NF; i++) printf "%s ", $i; printf "\n";}' > .new-maintainers
22
23 set +e
24 cmp .new-maintainers Maintainers >/dev/null
25 rc=$?
26 set -e
27 if [ $rc = 1 ] || [ ! -f Maintainers ] ; then
28         echo -n "installing Maintainers ... "
29         mv -f .new-maintainers Maintainers
30         gzip -9v <Maintainers >.new-maintainers.gz
31         mv -f .new-maintainers.gz Maintainers.gz
32 elif [ $rc = 0 ] ; then
33         echo '(same as before)'
34         rm -f .new-maintainers
35 else
36         echo cmp returned $rc
37         false
38 fi