cron.d/120synctrans: Allow overriding the server for downloading translations
authorFrank Lichtenheld <frank@lichtenheld.de>
Sun, 9 Sep 2007 13:35:09 +0000 (15:35 +0200)
committerFrank Lichtenheld <frank@lichtenheld.de>
Sun, 9 Sep 2007 13:35:09 +0000 (15:35 +0200)
Suggested by Helge Kreutzmann <debian -at- helgefjell de>

Since the translations in the main Debian archive are still way outdated, use
ddtp.debian.net for now. Make overriding $ddtp_ftpsite optional and fall back
to $ftpsite automatically if no seperate $ddtp_ftpsite is defined.

config.sh.sed.in
cron.d/120synctrans

index aecefa9f307b893002d963eb822bc81975814ab0..73d6b472c29a04f206fdb4c5f75ac0f3e19fdfa8 100644 (file)
@@ -31,6 +31,7 @@ volatile_ftpsite=http://volatile.debian.org/debian-volatile
 backports_ftpsite=http://backports.org/debian
 amd64_ftpsite=http://amd64.debian.net/debian
 gnuab_ftpsite=http://kfreebsd-gnu.debian.net/debian
+ddtp_ftpsite=http://ddtp.debian.net/debian
 
 root=""
 
index 12767abce8ae8a68fb25a6f98dd03f73cb588808..33c38be14ca05b6ed30bd1fd6aede5268f5a94cc 100755 (executable)
@@ -5,9 +5,13 @@
 test -d ${archivedir} || mkdir -p ${archivedir}
 cd ${archivedir}
 
-if [ -z "${localdir}" ]
+if [ -z "${localdir}" ] || [ -n "$ddtp_ftpsite" ]
 then
-    echo using remote mirror
+    if [ -z "$ddtp_ftpsite" ]
+    then
+       ddtp_ftpsite="$ftpsite"
+    fi
+    echo using remote mirror $ddtp_ftpsite
     for dist in sid
     do
        for part in main
@@ -17,7 +21,7 @@ then
          do
            echo retrieve translated Descs $dist/$part/$lang
             (cd us/${dist}/${part}/i18n &&
-                wget -q -N ${ftpsite}/dists/${dist}/${part}/i18n/Translations-$lang.gz)
+                wget -q -N ${ddtp_ftpsite}/dists/${dist}/${part}/i18n/Translations-$lang.gz)
          done
        done
     done