From ac2cc0cffafed15ef43e9f193fa67d6591cfdd96 Mon Sep 17 00:00:00 2001 From: Sami Vaarala Date: Thu, 20 Mar 2014 15:07:20 +0200 Subject: [PATCH] check for 'node' legacy command, suggest installing nodejs-legacy --- util/check_setup.sh | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/util/check_setup.sh b/util/check_setup.sh index b1225888..3eea3177 100755 --- a/util/check_setup.sh +++ b/util/check_setup.sh @@ -17,15 +17,22 @@ fi NODEJS_VERSION=`nodejs -v 2>/dev/null` if [ $? != 0 ]; then - NODE_VERSION=`node -v 2>/dev/null` - if [ $? != 0 ]; then - echo "*** Missing NodeJS:" - echo " $ sudo apt-get install nodejs npm # may also be 'node'" - echo "" - ERRORS=1 - fi + echo "*** Missing NodeJS:" + echo " $ sudo apt-get install nodejs nodejs-legacy npm # may also be 'node'" + echo "" + ERRORS=1 +fi +#echo "NodeJS version: $NODEJS_VERSION" + +# some tools like uglifyjs require 'node', not 'nodejs' +NODE_VERSION=`node -v 2>/dev/null` +if [ $? != 0 ]; then + echo "*** Missing NodeJS legacy ('node' command):" + echo " $ sudo apt-get install nodejs-legacy" + echo "" + ERRORS=1 fi -#echo "Node version: $NODE_VERSION" +#echo "NodeJS 'node' version: $NODE_VERSION" GIT_VERSION=`git --version 2>/dev/null` if [ $? != 0 ]; then