From 2a5e399769b3bee8f3d424f9afc9b2c21a76b90d Mon Sep 17 00:00:00 2001 From: Kaan Atakan <96086061+KaanSD@users.noreply.github.com> Date: Fri, 15 Dec 2023 20:34:16 +0300 Subject: [PATCH] fix(install.sh): remove url validation (false negatives, redundant) (#35) * fix(install.sh): remove url validation (false negatives, redundant) https://github.com/pnpm/pnpm/issues/7336 Removed url validation since it fails sometimes even though the actual download would succeed. It is also fairly pointless to begin with, only preventing the creation and deletion of a temporary directory. * chore: sign the updated script --------- Co-authored-by: Zoltan Kochan --- SHASUMS256.txt | 2 +- SHASUMS256.txt.sig | Bin 323 -> 323 bytes install.sh | 13 ------------- 3 files changed, 1 insertion(+), 14 deletions(-) diff --git a/SHASUMS256.txt b/SHASUMS256.txt index 292adc1..1041e88 100644 --- a/SHASUMS256.txt +++ b/SHASUMS256.txt @@ -4,5 +4,5 @@ d6e6538b8fa1147a58efac1ed2bf7f3311aecd5d8e1b11c0070794a5c5b151d8 v6.6.js c80817f1dac65ee497fc8ca0b533e497aacfbf951a917ff4652825710bbacda7 v6.14.js 675896fe510fe86a6c4812c46334aafe789a05dd60652cca768b78971ca2b906 v6.16.js be155eed896aa8c7900352c2b28640bcbace13171ec632b0e29f0ac94e5b27d1 v6.32.js -5b451a2e1899cf48b1363425e759ce986920be0b173b363ed4fa135a06756641 install.sh +89d38e03ff1a3ba5d74253570d9a8438db6f263c79c756a13b7fce2bd3f93f29 install.sh 7881ea9b132eb7c6d12db6f14ca55bbb5d251edf08693d570eac31ad0d00c827 install.ps1 diff --git a/SHASUMS256.txt.sig b/SHASUMS256.txt.sig index b7434a46cda5adec263eb83680f08ff705b2a5f2..3b5203ec05a57c2624c95708e6224f8487cf9947 100644 GIT binary patch delta 296 zcmV+@0oVS+0>c83B!7(F3>;^0XFzanaBVJWZvYAj5PZL2RVO}dwMN;Ido};od~hGUe}0FO9EQz>Z)u;UvT8hGzT=zv4#^yqGLr z2BdX_=FG-z9(i~6_s=Ipro-38l8OuvgtrT}VLeUq6Gi!*Cx6jqnX#H0EGmnfRz0jN zdDo4!8ABPex(!c?Kz*hPsp>lNRKg`BPx7Kq7`a#QvHH%VCao}w6ac#^j;d|g4xTO~ zLau00qOVd33c(?9{Wr7=k7M-KT_nJTfIwC7TE5EOR>NL1awkk(41IxCG_a*$^}~as u)5OH;C?sxA9wB_HGVuFT^;xz%+TplHUgWGWKSTttV^+8oP{$5e3gCs$@QKI( delta 296 zcmV+@0oVS+0>c83B!7Rl3>;^0XFzanaBVJWZvYAj5PZL2RVO}dwXkjn{w435IC&5Y zfWBemxQS1IPYt6IW@@t-dgBf4v;){L5?O0xY7-TX zDx&j)a=m2pwu$nt5T|}yP&KT2jUhFoO@yl?rk0rRHzVL{>XG+*BYg?vq=SY7T5ogZ uNY3Luf^R`O4k4wrrQ4+V+wVj%cX6Sd>dyxmX9K_pNL{N83R*V^U||tU@`7ss diff --git a/install.sh b/install.sh index 67abc2e..79f6fc2 100644 --- a/install.sh +++ b/install.sh @@ -31,17 +31,6 @@ download() { fi } -validate_url() { - local url - url="$1" - - if command -v curl > /dev/null 2>&1; then - curl --output /dev/null --silent --show-error --location --head --fail "$url" - else - wget --spider --quiet "$url" - fi -} - is_glibc_compatible() { getconf GNU_LIBC_VERSION >/dev/null 2>&1 || ldd --version >/dev/null 2>&1 || return 1 } @@ -106,8 +95,6 @@ download_and_install() { archive_url="${archive_url}.exe" fi - validate_url "$archive_url" || abort "pnpm version '${version}' could not be found" - # install to PNPM_HOME, defaulting to ~/.pnpm tmp_dir="$(mktemp -d)" || abort "Tmpdir Error!" trap 'rm -rf "$tmp_dir"' EXIT INT TERM HUP