]> git.deb.at Git - deb/packages.git/blob - cron.d/100syncarchive_installer
[UBUNTU] ubuntu.css: Remove obsolete stuff
[deb/packages.git] / cron.d / 100syncarchive_installer
1 #! /bin/bash
2
3 . `dirname $0`/../config.sh
4
5 test -d ${archivedir} || mkdir -p ${archivedir}
6 cd ${archivedir}
7
8 # Main archive
9 #
10 if [ -z "${localdir}" ]
11 then
12     echo using remote mirror
13     for dist in ${dists}
14     do
15
16       if [ $dist = experimental ]; then
17           continue
18       fi
19
20         foo=\$arch_${dist//-/_}
21         for arch in `eval echo $foo`
22         do
23             for part in $parts
24             do
25                 part="$part/debian-installer"
26                 echo retrieve Packages $dist/$part/$arch
27                 test -d us/${dist}/${part}/binary-${arch} || mkdir -p us/${dist}/${part}/binary-${arch}
28                 (cd us/${dist}/${part}/binary-${arch} &&
29                     $wget_cmd -N ${ftpsite}/dists/${dist}/${part}/binary-${arch}/Packages.gz)
30             done
31         done
32     done
33 else
34     echo using local mirror
35     for dist in ${dists}
36     do
37
38       if [ $dist = experimental ]; then
39           continue
40       fi
41
42         foo=\$arch_${dist//-/_}
43         for arch in `eval echo $foo`
44         do
45             for part in $parts
46             do
47                 part="$part/debian-installer"
48                 echo retrieve Sources $dist/$part/$arch
49                 test -d us/${dist}/${part}/binary-${arch} || mkdir -p us/${dist}/${part}/binary-${arch}
50                 rsync -t ${localdir}/dists/${dist}/${part}/binary-${arch}/Packages.gz \
51                     us/${dist}/${part}/binary-${arch}/Packages.gz
52             done
53         done
54     done
55 fi