From 754e319f3f7025b60e2d8c16037c9919489dd8c9 Mon Sep 17 00:00:00 2001 From: Thomas Metois Date: Wed, 1 Mar 2017 10:26:21 +0100 Subject: [PATCH] EVO: script-update > check if node_modules are installed else use "npm install" --- scripts/update-all.sh | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/scripts/update-all.sh b/scripts/update-all.sh index d60c839..ad37fd1 100755 --- a/scripts/update-all.sh +++ b/scripts/update-all.sh @@ -33,9 +33,18 @@ else pathFO="vendor/monarc/frontoffice" fi -pull_if_exists node_modules/ng_backoffice -pull_if_exists node_modules/ng_client -pull_if_exists node_modules/ng_anr +if [[ -d node_modules && -d node_modules/ng_anr ]]; then + if [[ -d node_modules/ng_anr/.git ]]; then + pull_if_exists node_modules/ng_backoffice + pull_if_exists node_modules/ng_client + pull_if_exists node_modules/ng_anr + else + npm update + fi +else + npm install +fi + if [ -d $pathCore ]; then php ./vendor/robmorgan/phinx/bin/phinx migrate -c ./$pathCore/migrations/phinx.php