mirror of
https://github.com/nvm-sh/nvm.git
synced 2025-08-20 04:23:43 +00:00
Compare commits
4 Commits
554e89d5ef
...
c80b89720f
Author | SHA1 | Date | |
---|---|---|---|
![]() |
c80b89720f | ||
![]() |
4792d122b1 | ||
![]() |
c31a867c46 | ||
![]() |
a8c418558a |
7
nvm.sh
7
nvm.sh
@ -128,7 +128,12 @@ nvm_download() {
|
||||
if nvm_curl_use_compression; then
|
||||
CURL_COMPRESSED_FLAG="--compressed"
|
||||
fi
|
||||
eval "curl -q --fail ${CURL_COMPRESSED_FLAG:-} ${CURL_HEADER_FLAG:-} $*"
|
||||
local NVM_DOWNLOAD_ARGS
|
||||
NVM_DOWNLOAD_ARGS=''
|
||||
for arg in "$@"; do
|
||||
NVM_DOWNLOAD_ARGS="${NVM_DOWNLOAD_ARGS} \"$arg\""
|
||||
done
|
||||
eval "curl -q --fail ${CURL_COMPRESSED_FLAG:-} ${CURL_HEADER_FLAG:-} ${NVM_DOWNLOAD_ARGS}"
|
||||
elif nvm_has "wget"; then
|
||||
# Emulate curl with wget
|
||||
ARGS=$(nvm_echo "$@" | command sed -e 's/--progress-bar /--progress=bar /' \
|
||||
|
@ -15,4 +15,6 @@ if nvm_download "https://raw.githubusercontent.com/nvm-sh/nvm/HEAD/wrong_install
|
||||
die "nvm_download should fail to download no existing file"
|
||||
fi
|
||||
|
||||
nvm_download "https://raw.githubusercontent.com/nvm-sh/nvm/HEAD/install.sh" -o "; die quoted-command-not-quoted"
|
||||
|
||||
cleanup
|
||||
|
Loading…
x
Reference in New Issue
Block a user