diff --git a/scripts/install.sh b/scripts/install.sh index b50144ee..5ccdb8de 100644 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -6,9 +6,16 @@ else INSTALL_DEVEL=0 fi +if [ "$2" == "local" ]; then + INSTALL_LOCALLY=1 +else + INSTALL_LOCALLY=0 +fi + # dir with meta informatou about installation INSTALL_METADATA_DIRECTORY=".install" +# if possible, do not change these paths - otherwise update could broke down WEBSITE_DOMAIN_FILE=$INSTALL_METADATA_DIRECTORY"/.website_domain" WEBSITE_PARENT_FILE=$INSTALL_METADATA_DIRECTORY"/.website_parent" DB_INITIALIZED_FILE=$INSTALL_METADATA_DIRECTORY"/.db_initialized" @@ -74,7 +81,12 @@ fi # fetch data from server if [ ! -n "$(ls -A)" ]; then - git clone git@binarity.cz:/opt/git/internal/cms/minicms.git -b $WEBSITE_PARENT . + + if [ $INSTALL_LOCALLY -eq 0 ]; then + git clone git@binarity.cz:/opt/git/internal/cms/minicms.git -b $WEBSITE_PARENT . + else + git clone /opt/git/internal/cms/minicms.git -b $WEBSITE_PARENT . + fi if [ ! $? -eq 0 ]; then echo ""