Mercurial > hg > aboriginal
changeset 582:d66eae57a344
Move mirror list into download.sh.
author | Rob Landley <rob@landley.net> |
---|---|
date | Tue, 13 Jan 2009 16:42:46 -0600 |
parents | 9dffdd74c186 |
children | 1bb180e6a4ba |
files | download.sh sources/functions.sh |
diffstat | 2 files changed, 8 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/download.sh Mon Jan 12 02:47:32 2009 -0600 +++ b/download.sh Tue Jan 13 16:42:46 2009 -0600 @@ -14,6 +14,10 @@ echo -e "$DOWNLOAD_COLOR" echo "=== Download source code." +# List of fallback mirrors for these files + +MIRROR_LIST="http://impactlinux.com/firmware/mirror http://landley.net/code/firmware/mirror" + # Note: a blank SHA1 value means accept anything, and the download script # prints out the sha1 of such files after downloading it, so to update to # a new version of a file, set SHA1= and update the URL, run ./download.sh,
--- a/sources/functions.sh Mon Jan 12 02:47:32 2009 -0600 +++ b/sources/functions.sh Tue Jan 13 16:42:46 2009 -0600 @@ -212,11 +212,12 @@ fi # Try standard locations + # Note: the URLs in mirror list cannot contain whitespace. - for i in "$URL" http://impactlinux.com/firmware/mirror/"$FILENAME" \ - http://landley.net/code/firmware/mirror/"$FILENAME" + try_download "$URL" && return 0 + for i in $MIRROR_LIST do - try_download "$i" && return 0 + try_download "$i/$FILENAME" && return 0 done # Return failure.