From 50b5e741fe6a9a90dddeee98253df5b5ef79dfd4 Mon Sep 17 00:00:00 2001 From: Christian Wiese Date: Wed, 21 Aug 2013 13:05:44 +0200 Subject: [PATCH] sde-download: improved to use download.mirror_list if it is set in ~/.sde/settings making mirror-list fetching more flexible --- bin/sde-download | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/bin/sde-download b/bin/sde-download index 0722643..8afd556 100755 --- a/bin/sde-download +++ b/bin/sde-download @@ -212,9 +212,13 @@ detect_mirror() { echo_warning "Auto-detecting best mirror ..." - echo_info "Downloading mirror-list from opensde.net." + if [ -z "$mirror_list" ]; then + mirror_list="http://opensde.net/opensde-download-mirrors" + fi + + echo_info "Downloading mirror-list from $mirror_list" curl -s -S $curl_options -o tmp/Download-Mirror-List \ - "http://opensde.net/opensde-download-mirrors/$pkgver" + "$mirror_list/$pkgver" if [ -r tmp/Download-Mirror-List ]; then bash lib/sde-download/mirror-test.sh < tmp/Download-Mirror-List