1
0
Fork 0
mirror of https://github.com/overleaf/toolkit.git synced 2025-04-20 15:58:06 +02:00

Keep version in config, seed during init

This commit is contained in:
Shane Kilkelly 2020-07-09 11:23:14 +01:00
parent ba1e87e60e
commit fb3f409797
3 changed files with 5 additions and 2 deletions

View file

@ -5,7 +5,7 @@ set -euo pipefail
RC_FILE="config/overleaf.rc"
function __main__() {
SHARELATEX_IMAGE_VERSION="$(head -n 1 ./lib/sharelatex-image-version)"
SHARELATEX_IMAGE_VERSION="$(head -n 1 ./config/version)"
MONGO_IMAGE="mongo:3.6"
REDIS_IMAGE="redis:5.0"

View file

@ -10,7 +10,9 @@ function usage() {
}
function check_existing_config() {
if [[ -f ./config/overleaf.rc ]] || [[ -f ./config/variables.env ]]; then
if [[ -f ./config/overleaf.rc ]] \
|| [[ -f ./config/variables.env ]] \
|| [[ -f ./config/version ]]; then
echo "ERROR: Config files already exist, exiting "
exit 1
fi
@ -20,6 +22,7 @@ function set_up_config_files() {
echo "Copying config files to 'config/'"
cp ./lib/config-seed/overleaf.rc ./config/
cp ./lib/config-seed/variables.env ./config/
cp ./lib/config-seed/version ./config/
}
function __main__() {