tools: fix nghttp3 updater script

PR-URL: https://github.com/nodejs/node/pull/56007
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
pull/56067/head
Antoine du Hamel 2024-11-28 23:52:23 +00:00 committed by GitHub
parent 4cf6fabce2
commit 0a9524bd35
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 7 additions and 6 deletions

View File

@ -42,16 +42,17 @@ cleanup () {
trap cleanup INT TERM EXIT
NGHTTP3_REF="v$NEW_VERSION"
NGHTTP3_ZIP="nghttp3-$NEW_VERSION"
ARCHIVE_BASENAME="nghttp3-${NEW_VERSION}"
cd "$WORKSPACE"
echo "Fetching nghttp3 source archive..."
curl -sL -o "$NGHTTP3_ZIP.zip" "https://github.com/ngtcp2/nghttp3/archive/refs/tags/$NGHTTP3_REF.zip"
log_and_verify_sha256sum "nghttp3" "$NGHTTP3_ZIP.zip"
unzip "$NGHTTP3_ZIP.zip"
rm "$NGHTTP3_ZIP.zip"
mv "$NGHTTP3_ZIP" nghttp3
curl -sL -o "$ARCHIVE_BASENAME.tar.xz" "https://github.com/ngtcp2/nghttp3/releases/download/${NGHTTP3_REF}/${ARCHIVE_BASENAME}.tar.xz"
SHA256="$(curl -sL "https://github.com/ngtcp2/nghttp3/releases/download/${NGHTTP3_REF}/checksums.txt" | grep 'tar.xz$')"
log_and_verify_sha256sum "nghttp3" "$ARCHIVE_BASENAME.tar.xz" "$SHA256"
tar -xJf "$ARCHIVE_BASENAME.tar.xz"
rm "$ARCHIVE_BASENAME.tar.xz"
mv "$ARCHIVE_BASENAME" nghttp3
cd nghttp3