summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorKonstantin Käfer <mail@kkaefer.com>2014-10-21 13:04:22 +0200
committerKonstantin Käfer <mail@kkaefer.com>2014-10-21 13:04:22 +0200
commite98b3e5d86f4108075e8814155ed9b684f99439c (patch)
tree7e6f3de7da13c6bb290221d9d255cce1af9949b7 /configure
parentab42c0cf936758192f384589e80b4c9693d1146d (diff)
downloadqtlocation-mapboxgl-e98b3e5d86f4108075e8814155ed9b684f99439c.tar.gz
install nvm and node
[skip ci]
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure12
1 files changed, 11 insertions, 1 deletions
diff --git a/configure b/configure
index e943690513..3e26c7e428 100755
--- a/configure
+++ b/configure
@@ -5,8 +5,18 @@ set -o pipefail
CONFIG_FILE=${1:-config.gypi}
+# Install node
+if [[ ! -d ~/.nvm ]]; then
+ git clone --depth 1 https://github.com/creationix/nvm.git ~/.nvm
+fi
+set +u
. ~/.nvm/nvm.sh
-nvm use 0.10
+if [ ! `nvm use 0.10 > /dev/null; echo $?` = 0 ]; then
+ >&2 echo -e "\033[1m\033[32m* $(nvm install 0.10)\033[0m";
+else
+ >&2 echo -e "\033[1m\033[32m* $(nvm use 0.10)\033[0m";
+fi
+
case $MASON_PLATFORM in
'ios')