diff --git a/create.sh b/create.sh index aa59159..5c69aa9 100644 --- a/create.sh +++ b/create.sh @@ -12,18 +12,23 @@ mkdir /var/www/gitwrapper/$name cd /var/www/gitwrapper/$name chmod 777 . echo `pwd` - +echo '=============' DJANGO_SETTINGS_MODULE=project.settings.prod export DJANGO_SETTINGS_MODULE=project.settings.prod git clone $sshURL . git checkout prod +git status +echo "==================" + + # change https urls to ssh perl -pi -e 's/https:\/\/github.com\//ssh:\/\/git@github.com:/g' .gitmodules +git submodule sync ./scripts/setup.sh - +git stash cp /var/www/local_settings.py project/settings/local_settings.py echo "BRANCH = '$name'" >> project/settings/local_settings.py @@ -37,6 +42,7 @@ echo "BRANCH = '$name'" >> project/settings/local_settings.py git checkout $name # change https urls to ssh perl -pi -e 's/https:\/\/github.com\//ssh:\/\/git@github.com:/g' .gitmodules +git submodule sync ./scripts/setup.sh git stash # python3 manage.py collectstatic --noinput