summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2019-01-21 12:40:59 +0100
committerErich Eckner <git@eckner.net>2019-01-21 12:40:59 +0100
commit6801e5f9e488b5e2e840c4ce518129f59fc04985 (patch)
treee9d339ca35b1f95336ce481021119fcb1cbed09c
parent93bb4be796e1daa43721121b1d08eb1aaad698ed (diff)
downloadbuilder-6801e5f9e488b5e2e840c4ce518129f59fc04985.tar.xz
bin/clean-dependencies: show more progress, abort when curl fails
-rwxr-xr-xbin/clean-dependencies8
1 files changed, 6 insertions, 2 deletions
diff --git a/bin/clean-dependencies b/bin/clean-dependencies
index a9105fb..a2da6ef 100755
--- a/bin/clean-dependencies
+++ b/bin/clean-dependencies
@@ -34,9 +34,13 @@ trap 'rm "${deps_file}"' EXIT
printf ' AND `install_targets`.`name` NOT IN ("base","base-devel");\n'
} | \
mysql_run_query | \
- pv --line-mode | \
while read -r id path; do
- curl -Ss "https://pkgapi.archlinux32.org/$path" | \
+ >&2 printf '.'
+ infos=$(
+ curl -Ss "https://pkgapi.archlinux32.org/$path"
+ ) || \
+ continue
+ printf '%s\n' "${infos}" | \
sed '
s/^.*"Requires":\("[^"]\+"\|\[[^[]]\+\]\).*$/\1/
t