Compare commits

...

3 Commits

Author SHA1 Message Date
ryenus
0e71486e1d
Merge e183c44d5a9a830f73c8a14285070c628748ad85 into 762f9ef9d17623b45095e8ca1a996c8928f3f424 2024-07-07 21:10:19 +09:00
Jordan Harband
762f9ef9d1
[Tests] only install python 2.7 if not already installed
See ee6f7667 / #3067
2024-07-06 10:29:55 -05:00
ryenus
e183c44d5a bypass aliased curl
Meanwhile keeping nvm_curl_version and nvm_curl_libz_support as-is
to avoid breaking tests which redefines `curl` as a shell function.
2023-01-10 16:44:11 +08:00
3 changed files with 4 additions and 4 deletions

View File

@ -32,7 +32,7 @@ before_install:
- zsh --version
- dpkg -s dash | grep ^Version | awk '{print $2}'
# install python
- pyenv install 2.7.18
- pyenv local 2.7.18 || pyenv install 2.7.18
- pyenv local 2.7.18 || echo 'pyenv failed'
- python -V
install:

View File

@ -106,7 +106,7 @@ nvm_node_version() {
nvm_download() {
if nvm_has "curl"; then
curl --fail --compressed -q "$@"
command curl --fail --compressed -q "$@"
elif nvm_has "wget"; then
# Emulate curl with wget
ARGS=$(nvm_echo "$@" | command sed -e 's/--progress-bar /--progress=bar /' \

4
nvm.sh
View File

@ -101,7 +101,7 @@ nvm_get_latest() {
if nvm_curl_use_compression; then
CURL_COMPRESSED_FLAG="--compressed"
fi
NVM_LATEST_URL="$(curl ${CURL_COMPRESSED_FLAG:-} -q -w "%{url_effective}\\n" -L -s -S https://latest.nvm.sh -o /dev/null)"
NVM_LATEST_URL="$(command curl ${CURL_COMPRESSED_FLAG:-} -q -w "%{url_effective}\\n" -L -s -S https://latest.nvm.sh -o /dev/null)"
elif nvm_has "wget"; then
NVM_LATEST_URL="$(wget -q https://latest.nvm.sh --server-response -O /dev/null 2>&1 | command awk '/^ Location: /{DEST=$2} END{ print DEST }')"
else
@ -121,7 +121,7 @@ nvm_download() {
if nvm_curl_use_compression; then
CURL_COMPRESSED_FLAG="--compressed"
fi
curl --fail ${CURL_COMPRESSED_FLAG:-} -q "$@"
command curl --fail ${CURL_COMPRESSED_FLAG:-} -q "$@"
elif nvm_has "wget"; then
# Emulate curl with wget
ARGS=$(nvm_echo "$@" | command sed -e 's/--progress-bar /--progress=bar /' \