Skip to content

Commit

Permalink
Re-add --server-response in order to give user nice output
Browse files Browse the repository at this point in the history
  • Loading branch information
andsens committed Apr 26, 2024
1 parent d215788 commit 63d87e1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion upkg.sh
Original file line number Diff line number Diff line change
Expand Up @@ -502,7 +502,7 @@ upkg_fetch() {
local url="$1" dest="$2" out
processing "Downloading %s" "$url"
if type wget >/dev/null 2>&1; then
wget -qO "$dest" "$url" || fatal "Error while downloading '%s'" "$url"
out=$(wget --server-response -qO "$dest" "$url" 2>&1) || fatal "Error while downloading '%s', server response:\n%s" "$url" "$out"
elif type curl >/dev/null 2>&1; then
curl -fsLo "$dest" "$url" || fatal "Error while downloading '%s'" "$url"
else
Expand Down

0 comments on commit 63d87e1

Please sign in to comment.