Skip to content

Commit 41d6c4e

Browse files
authored
Invoke curl without using user's ~/.curlrc config (#224)
The idea is that a `~/.curlrc` can contain options that change the output, like `-w`, which can cause downstream tooling (like `tar`) to fail. In this case, we want `curl` to behave consistently regardless of how the user has configured curl. Fix #223
1 parent c69e5d1 commit 41d6c4e

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

functions/_nvm_index_update.fish

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ function _nvm_index_update
33

44
set --local index $nvm_data/.index
55

6-
if not command curl --location --silent $nvm_mirror/index.tab >$index.temp
6+
if not command curl -q --location --silent $nvm_mirror/index.tab >$index.temp
77
command rm -f $index.temp
88
echo "nvm: Can't update index, host unavailable: \"$nvm_mirror\"" >&2
99
return 1

functions/nvm.fish

+1-1
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ function nvm --description "Node version manager"
113113
echo -e "Fetching \x1b[4m$url\x1b[24m\x1b[7m"
114114
end
115115

116-
if ! command curl $silent --progress-bar --location $url |
116+
if ! command curl -q $silent --progress-bar --location $url |
117117
command tar --extract --gzip --directory $nvm_data/$ver 2>/dev/null
118118
command rm -rf $nvm_data/$ver
119119
echo -e "\033[F\33[2K\x1b[0mnvm: Invalid mirror or host unavailable: \"$url\"" >&2

0 commit comments

Comments
 (0)