From dcf271a01b0f2b01f65b6ffd51aa5fabc515f62e Mon Sep 17 00:00:00 2001 From: Vivian Phung Date: Mon, 26 Feb 2024 18:06:24 -0500 Subject: [PATCH] Build webapp script fix (#111) * build-webapp-script-fix * build-webapp-script-fix --- .gitignore | 1 + build-webapp.sh | 8 ++++++++ 2 files changed, 9 insertions(+) diff --git a/.gitignore b/.gitignore index 5bbf8847..2cbbca9c 100644 --- a/.gitignore +++ b/.gitignore @@ -2,5 +2,6 @@ node_modules/ yarn-error.log .yarnrc.yml .yarn/ +.yarnrc packages/backend/environments/local.toml \ No newline at end of file diff --git a/build-webapp.sh b/build-webapp.sh index a77ec641..b22dde5d 100755 --- a/build-webapp.sh +++ b/build-webapp.sh @@ -9,6 +9,14 @@ if [[ -d "$DEST_DIR" ]]; then exit 1 fi +if [[ -f "$PKG_DIR/.env" ]]; then + echo "Using existing .env file" +else + mv "$PKG_DIR/.env.example" "$PKG_DIR/.env" + echo "Created .env file. Please populate with the correct values." + exit 1 +fi + cat > $PKG_DIR/.env <