]> git.decadent.org.uk Git - dak.git/blobdiff - scripts/debian/mkfilesindices
First pass at lenny release branch
[dak.git] / scripts / debian / mkfilesindices
index 34d1b6bcd63e1c8bff1815b9689bec86499e0fb3..3a96ec551c675736fa9c8c88c0a33ca24bea8311 100755 (executable)
@@ -10,7 +10,7 @@ ARCHLIST=$(tempfile)
 
 echo "Querying projectb..."
 
-echo 'SELECT l.path, f.filename, a.arch_string FROM location l JOIN files f ON (f.location = l.id) LEFT OUTER JOIN (binaries b JOIN architecture a ON (b.architecture = a.id)) ON (f.id = b.file)' | psql projectb -At | sed 's/|//;s/|all$/|/;s,^/srv/ftp.debian.org/ftp,.,' | sort >$ARCHLIST
+echo 'SELECT l.path, f.filename, a.arch_string FROM location l JOIN files f ON (f.location = l.id) LEFT OUTER JOIN (binaries b JOIN architecture a ON (b.architecture = a.id)) ON (f.id = b.file)' | psql projectb -At | sed 's/|//;s,^/srv/ftp.debian.org/ftp,.,' | sort >$ARCHLIST
 
 includedirs () {
     perl -ne 'print; while (m,/[^/]+$,) { $_=$`; print $_ . "\n" unless $d{$_}++; }'
@@ -31,16 +31,14 @@ echo "Generating sources list..."
 
 echo "Generating arch lists..."
 
-ARCHES=$( (<$ARCHLIST sed -n 's/^.*|//p'; echo amd64) | grep . | sort -u)
+ARCHES=$( (<$ARCHLIST sed -n 's/^.*|//p'; echo amd64) | grep . | grep -v all | sort -u)
 for a in $ARCHES; do
   (sed -n "s/|$a$//p" $ARCHLIST
+   sed -n 's/|all$//p' $ARCHLIST
 
    cd $base/ftp
    find ./dists -maxdepth 1 \! -type d
    find ./dists \! -type d | grep -E "(proposed-updates.*_$a.changes$|/main/disks-$a/|/main/installer-$a/|/Contents-$a|/binary-$a/)"
-   if echo X sparc mips mipsel hppa X | grep -q " $a "; then
-     find ./dists/sarge/main/upgrade-kernel \! -type d
-   fi
   ) | sort -u | gzip -9 > arch-$a.list.gz
 done
 
@@ -83,7 +81,13 @@ for a in $ARCHES; do
     sort -u | poolfirst > ../arch-$a.files
 done
 
-(cat ../arch-i386.files ../arch-amd64.files; zcat suite-stable.list.gz) |
+(cd $base/ftp/
+       for dist in sid lenny; do
+               find ./dists/$dist/main/i18n/ \! -type d | sort -u | gzip -9 > $base/ftp/indices/files/components/translation-$dist.list.gz
+       done
+)
+
+(cat ../arch-i386.files ../arch-amd64.files; zcat suite-oldstable.list.gz suite-proposed-updates.list.gz ; zcat translation-sid.list.gz ; zcat translation-lenny.list.gz) |
    sort -u | poolfirst > ../typical.files
 
 rm -f $ARCHLIST