diff --git a/script.sh b/script.sh index cf6cf78b450fdaabab90a269889a50305cff2764..0610293616d1f38f3acc7d7de644544aad7c67e7 100644 --- a/script.sh +++ b/script.sh @@ -1,13 +1,12 @@ #! /bin/sh - #console command PYTHON="python" #console command for python PIP="pip3" #console command for pip #bool -NEWINSTALL=true #clone everything / just update -LAUNCHMAIN=true #start example at the end -LocalOnly=false # don't look for last release online and compile with local work instead +NEWINSTALL=true # true : New project installation / false : project update +LAUNCHMAIN=true # true : launch main before exit +LocalOnly=false # true : don't watch online updates, just compile the local version #branch COREBRANCH="master" @@ -20,7 +19,6 @@ function compilelib { } function updateremote { - BranchToCompil=$1 IsLib=$2 PathToLib=$3 @@ -31,7 +29,7 @@ function updateremote { git pull git checkout $BranchToCompil git pull - + if [ $IsLib = true ]; then compilelib "$PathToLib" else @@ -39,18 +37,15 @@ function updateremote { $PYTHON ./philosophersLaunchExample.py else read -p "Main is ready, press any key to unstash work and return to older version" - fi + fi fi git checkout $CURRENTBRANCH git stash pop } - if [ $NEWINSTALL = true ]; then - $PIP install matplotlib $PIP install wheel - git clone https://gitlab.com/be-pyamak/pyamak-ihm.git git clone https://gitlab.com/be-pyamak/pyamak-noyau.git git clone https://gitlab.com/be-pyamak/philosopher_example.git