Skip to content
Myr

[Fix] `nvm_get_arch`: add `command` prefix to `uname` call

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Other `uname` calls in the file use `command uname` to bypass any user aliases or functions. This one was missing it. Bug introduced in https://github.com/nvm-sh/nvm/commit/779a34e6a9adcb6528e63d595a7a8838747e7915 / #2469.

authored by Jordan Harband · committed by Jordan Harband · parent d2fca5f · Browse files · 1 file+1 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−1 removed

  • other:+1 added−1 removed

1 file+1 added−1 removed

modified:nvm.sh+1 added-1 removed
2160 unmodified lines
2161 fi21622163 # If running a 64bit ARM kernel but a 32bit ARM userland,2164 # change ARCH to 32bit ARM (armv7l) if /sbin/init is 32bit executable2165 if [ "$(uname)" = "Linux" ] \2165 if [ "$(command uname)" = "Linux" ] \2166 && [ "${NVM_ARCH}" = arm64 ] \2167 && [ "$(command od -An -t x1 -j 4 -N 1 "/sbin/init" 2>/dev/null)" = ' 01' ]\2168 ; then2169 NVM_ARCH=armv7l
2648 unmodified lines