Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Brandt <mail@cebe.cc>2017-08-18 17:46:03 +0300
committerRebecca Turner <me@re-becca.org>2017-08-19 03:15:28 +0300
commit5ec72ab5b27c5c83cee9ff568cf75a9479d4b83a (patch)
treed64ad2ecf3bae625340f90cf5a8efc380d119da3 /scripts
parentf4650b5d4b2be2c04c229cc53aa930e260af9b4e (diff)
scripts: Make install.sh find nodejs on debian
Credit: @cebe Reviewed-By: @iarna PR-URL: https://github.com/npm/npm/pull/18229
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/install.sh5
1 files changed, 5 insertions, 0 deletions
diff --git a/scripts/install.sh b/scripts/install.sh
index 8ec16f95b..a5ce5311f 100755
--- a/scripts/install.sh
+++ b/scripts/install.sh
@@ -53,6 +53,11 @@ export npm_config_loglevel
# make sure that node exists
node=`which node 2>&1`
ret=$?
+# if not found, try "nodejs" as it is the case on debian
+if [ $ret -ne 0 ]; then
+ node=`which nodejs 2>&1`
+ ret=$?
+fi
if [ $ret -eq 0 ] && [ -x "$node" ]; then
(exit 0)
else