From ed9232d04bb4b8fd175f6c3002cf4fd265c17af2 Mon Sep 17 00:00:00 2001 From: Simon Doppler Date: Mon, 7 Aug 2017 17:12:05 +0200 Subject: Do not duplicate mirrors on the second run --- al32-mktorrent.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/al32-mktorrent.sh b/al32-mktorrent.sh index 3c1090a..b5aaff7 100644 --- a/al32-mktorrent.sh +++ b/al32-mktorrent.sh @@ -29,6 +29,7 @@ fg_bold="\033[1m" MIRRORLIST_FILE="https://raw.githubusercontent.com/archlinux32/packages/master/core/pacman-mirrorlist/mirrorlist" function create_torrent_for_arch () { + declare -a available_mirrors mirrorlist="$(curl "$MIRRORLIST_FILE" 2>/dev/null | grep Server | cut -d '=' -f 2 | sed -e 's/\s//g;s_$arch/$repo_archisos/_')" if [ "$#" -eq 0 ] ; then @@ -92,7 +93,6 @@ function create_torrent_for_arch () { ### Actual program declare -a architectures=("i686" "dual") -declare -a available_mirrors iso_date='' while getopts "d:h" o; do -- cgit v1.2.3-70-g09d2