public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Alex Legler" <a3li@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] sites/www:master commit in: bin/
Date: Fri, 27 May 2016 12:07:17 +0000 (UTC)	[thread overview]
Message-ID: <1464350445.dcaba6a3d14c9ec4b6424c304ddd7e99aec71235.a3li@gentoo> (raw)

commit:     dcaba6a3d14c9ec4b6424c304ddd7e99aec71235
Author:     Alex Legler <alex <AT> a3li <DOT> li>
AuthorDate: Fri May 27 12:00:23 2016 +0000
Commit:     Alex Legler <a3li <AT> gentoo <DOT> org>
CommitDate: Fri May 27 12:00:45 2016 +0000
URL:        https://gitweb.gentoo.org/sites/www.git/commit/?id=dcaba6a3

Whitespace

 bin/update-downloads.sh | 77 +++++++++++++++++++++++++------------------------
 1 file changed, 39 insertions(+), 38 deletions(-)

diff --git a/bin/update-downloads.sh b/bin/update-downloads.sh
index 3b0b894..b113fdb 100755
--- a/bin/update-downloads.sh
+++ b/bin/update-downloads.sh
@@ -6,75 +6,76 @@ URI_BASE="http://distfiles.gentoo.org/releases"
 ARCHES=(alpha amd64 arm hppa ia64 mips ppc s390 sh sparc x86)
 
 usage() {
-	cat <<EOF
+  cat <<EOF
 Usage: update-downloads.sh
 
 Helper script that runs on the servers to refresh the files that back the
 downloads page: https://gentoo.org/downloads/
 EOF
-	exit 0
+  exit 0
 }
 
 fetch() {
-	wget -T 60 -q "$@"
+  wget -T 60 -q "$@"
 }
 
 # Append extra images to the specified list.
 # append_list <local file> <list of remote urls to append>
 append_list() {
-	local list=$1 file
-	shift
-	for file in "$@" ; do
-		fetch -O - >>"${list}" "${uri_base}/${file}"
-	done
+  local list=$1 file
+  shift
+  for file in "$@"; do
+    fetch -O - >>"${list}" "${uri_base}/${file}"
+  done
 }
 
 update_amd64() {
-	append_list "${boot_list}" "latest-admincd-amd64.txt"
+  append_list "${boot_list}" "latest-admincd-amd64.txt"
 }
 
 update_hppa() {
-	append_list "${boot_list}" latest-netboot-hppa{32,64}.txt
+  append_list "${boot_list}" latest-netboot-hppa{32,64}.txt
 }
 
 update_s390() {
-	append_list "${boot_list}" latest-netboot-s390{,x}-{initramfs,kernel}.txt
+  append_list "${boot_list}" latest-netboot-s390{,x}-{initramfs,kernel}.txt
 }
 
 update_x86() {
-	append_list "${boot_list}" "latest-admincd-x86.txt"
+  append_list "${boot_list}" "latest-admincd-x86.txt"
 }
 
 # Update the bootable & stage lists.
 update_arch() {
-	local arch=$1
-	local uri_base="${URI_BASE}/${arch}/autobuilds"
-	local list_base="_data/downloads/${arch}"
-	local boot_list="${list_base}/iso.txt"
-	local stage_list="${list_base}/stage3.txt"
-
-	mkdir -p "${list_base}"
-	fetch "${uri_base}/latest-iso.txt" -O "${boot_list}"
-	fetch "${uri_base}/latest-stage3.txt" -O "${stage_list}"
-	if [[ $(type -t "update_${arch}") == "function" ]] ; then
-		update_${arch}
-	fi
+  local arch=$1
+  local uri_base="${URI_BASE}/${arch}/autobuilds"
+  local list_base="_data/downloads/${arch}"
+  local boot_list="${list_base}/iso.txt"
+  local stage_list="${list_base}/stage3.txt"
+
+  mkdir -p "${list_base}"
+  fetch "${uri_base}/latest-iso.txt" -O "${boot_list}"
+  fetch "${uri_base}/latest-stage3.txt" -O "${stage_list}"
+  if [[ $(type -t "update_${arch}") == "function" ]]; then
+    update_${arch}
+  fi
 }
 
 main() {
-	if [[ $# -ne 0 ]] ; then
-		usage
-	fi
-
-	# Make sure we're in the top level dir.
-	cd "$(dirname "$0")"/..
-
-	local arch
-	printf 'Updating ... '
-	for arch in "${ARCHES[@]}" ; do
-		printf '%s ' "${arch}"
-		update_arch "${arch}"
-	done
-	echo '... done'
+  if [[ $# -ne 0 ]]; then
+    usage
+  fi
+
+  # Make sure we're in the top level dir.
+  cd "$(dirname "$0")"/..
+
+  local arch
+  printf 'Updating downloads... '
+  for arch in "${ARCHES[@]}"; do
+    printf '%s ' "${arch}"
+    update_arch "${arch}"
+  done
+  echo 'done.'
 }
+
 main "$@"


             reply	other threads:[~2016-05-27 12:07 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-27 12:07 Alex Legler [this message]
  -- strict thread matches above, loose matches on Subject: below --
2017-07-28  4:15 [gentoo-commits] sites/www:master commit in: bin/ Matthew Marchese
2017-07-28  4:15 Matthew Marchese
2017-02-19  0:46 Robin H. Johnson
2016-07-18  6:22 Robin H. Johnson
2016-05-27 12:07 Alex Legler
2016-03-23 17:40 Robin H. Johnson
2015-10-04 21:12 Alex Legler
2015-08-10  9:20 Alex Legler
2015-05-19 12:55 Alex Legler

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1464350445.dcaba6a3d14c9ec4b6424c304ddd7e99aec71235.a3li@gentoo \
    --to=a3li@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox