Skip to content

Commit

Permalink
Make sure there is no old data on curl retries
Browse files Browse the repository at this point in the history
  • Loading branch information
tnozicka committed Oct 4, 2023
1 parent 3ce504a commit cafc724
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion golang/1.20/download-file.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ sha="$2"
tmp="$( mktemp )"
trap 'rm -f ${tmp}' EXIT

curl --fail --retry 5 --retry-all-errors -L "${url}" > "${tmp}"
curl --fail --retry 5 --retry-all-errors -L "${url}" -o "${tmp}"

sha512sum -c <( echo "${sha} ${tmp}" ) > /dev/stderr

Expand Down

0 comments on commit cafc724

Please sign in to comment.