Hello.

Reinhard Tartler:

> On 11/13/05, Shot - Piotr Szotkowski <[EMAIL PROTECTED]> wrote:

>> Does this tool require mirroring of the whole
>> archive(s) or just the Packages and Sources files?

> please look in /usr/share/doc/madison-lite/*

Er, right. Silly me. Thanks. :o)

Based on the examples, I created a much simpler script that works
for my much smaller needs (attached, if anyone else finds it useful).

Is there a way to ask wget to not download the *.gz files if
they have the same size and timestamp locally as on the server?

The wget manpage suggests -N should be enough, but it doesn't work for
me; the files are created with proper timestamps (2005-11-11 21:44 for
experimental's main sources, for example), but are re-downloaded each
time.

Cheers,
-- Shot
-- 
              If I have pinged farther than others, it is because
              I routed upon the T3s of giants.    -- Greg Andrews
====================== http://shot.pl/hovercraft/ === http://shot.pl/1/125/ ===
#!/bin/sh -e

mirror='/home/shot/ubuntu/madison-lite/mirror'
madison_conf='/home/shot/.madison-lite/config'

deb_dists='unstable experimental'
deb_parts='main contrib non-free'

ub_dists='breezy breezy-security breezy-updates breezy-backports dapper 
dapper-security dapper-updates'
ub_parts='main restricted universe multiverse'

wget='wget -N -O'

cd $mirror
echo mirror $mirror > $madison_conf

for dist in $deb_dists; do
  for part in $deb_parts; do
    mkdir -p $dist/$part/binary-i386
    mkdir -p $dist/$part/source
    $wget $dist/$part/binary-i386/Packages.gz 
http://ftp.debian.org/debian/dists/$dist/$part/binary-i386/Packages.gz
    $wget $dist/$part/source/Sources.gz 
http://ftp.debian.org/debian/dists/$dist/$part/source/Sources.gz
  done
  echo suite $dist $dist >> $madison_conf
done

for dist in $ub_dists; do
  for part in $ub_parts; do
    mkdir -p $dist/$part/binary-i386
    mkdir -p $dist/$part/source
    $wget $dist/$part/binary-i386/Packages.gz 
http://archive.ubuntu.com/ubuntu/dists/$dist/$part/binary-i386/Packages.gz
    $wget $dist/$part/source/Sources.gz 
http://archive.ubuntu.com/ubuntu/dists/$dist/$part/source/Sources.gz
  done
  echo suite $dist $dist >> $madison_conf
done

Attachment: signature.asc
Description: Digital signature

-- 
ubuntu-backports mailing list
[email protected]
http://lists.ubuntu.com/mailman/listinfo/ubuntu-backports

Reply via email to