aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Tom Willemse2022-06-18 20:59:10 -0700
committerGravatar Tom Willemse2022-06-18 20:59:10 -0700
commitae4693a15578d5965a74def4eb8615d6034aef6a (patch)
tree6bd0d0e0c76c3a78ae790cd69cac3d3798777cc7
parent565813b43ef351489bf1278679d45006e7c2634c (diff)
downloadupdate-mirrors-ae4693a15578d5965a74def4eb8615d6034aef6a.tar.gz
update-mirrors-ae4693a15578d5965a74def4eb8615d6034aef6a.zip
Show error messages generated by ‘curl’
The ‘-s’ switch makes ‘curl’ completely silent, even on error messages. So when it fails it doesn't tell us why. The ‘--no-progress-meter’ disables the normal progress meter output so that when everything succeeds, there is no output, but when there is a failure we still get to see what that is.
-rwxr-xr-xupdate-mirrors2
1 files changed, 1 insertions, 1 deletions
diff --git a/update-mirrors b/update-mirrors
index 8cf158f..4035fea 100755
--- a/update-mirrors
+++ b/update-mirrors
@@ -65,7 +65,7 @@ sudo." | fold >&2
fi
# Download, ready, output
-mirrorlist=$(curl -s -L "$(make-url)")
+mirrorlist=$(curl --no-progress-meter -L "$(make-url)")
if [[ $? -eq 0 ]]; then
echo "$mirrorlist" | sed 's/^#\([^#].*\)/\1/' > "$dest"