From 45ae48df2d2db54bea32e430e501df89f80aa761 Mon Sep 17 00:00:00 2001 From: Jordan Harband Date: Mon, 13 Jun 2016 08:41:17 -0700 Subject: [PATCH] =?UTF-8?q?[Fix]=20`nvm=20install=20-s`:=20when=20?= =?UTF-8?q?=E2=80=9Ccore=20id=E2=80=9D=20doesn=E2=80=99t=20appear=20in=20/?= =?UTF-8?q?proc/cpuinfo,=20fall=20back=20to=20counting=20=E2=80=9Cprocesso?= =?UTF-8?q?r=E2=80=9D=20lines.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixes #1115. --- nvm.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nvm.sh b/nvm.sh index d322091..502f409 100644 --- a/nvm.sh +++ b/nvm.sh @@ -1423,7 +1423,7 @@ nvm_get_make_jobs() { NVM_OS="$(nvm_get_os)" local NVM_CPU_THREADS if [ "_$NVM_OS" = "_linux" ]; then - NVM_CPU_THREADS="$(grep -c 'core id' /proc/cpuinfo)" + NVM_CPU_THREADS="$(command grep -c -E '^processor.+: [0-9]+' /proc/cpuinfo)" elif [ "_$NVM_OS" = "_freebsd" ] || [ "_$NVM_OS" = "_darwin" ]; then NVM_CPU_THREADS="$(sysctl -n hw.ncpu)" elif [ "_$NVM_OS" = "_sunos" ]; then