From 3f261d2bbb42057faf9bc0534869111d56f5fbd8 Mon Sep 17 00:00:00 2001 From: skywalker Date: Wed, 28 Aug 2024 21:44:40 +0300 Subject: [PATCH] chore(dev): add `CI=false` --- .github/workflows/cicd.yml | 2 ++ client/src/shared/cookie/cookie.ts | 2 +- tools/scripts/client/build.sh | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/cicd.yml b/.github/workflows/cicd.yml index 667886e6..3792abb5 100644 --- a/.github/workflows/cicd.yml +++ b/.github/workflows/cicd.yml @@ -191,6 +191,8 @@ jobs: run: npm i -g @redocly/cli@latest - name: Install Dependencies run: npm install --prefix client + env: + CI: false - name: Deploy at home lab run: echo "$(pwd)" && ./tools/scripts/deploy.sh dev env: diff --git a/client/src/shared/cookie/cookie.ts b/client/src/shared/cookie/cookie.ts index 22eb35f1..63e18542 100644 --- a/client/src/shared/cookie/cookie.ts +++ b/client/src/shared/cookie/cookie.ts @@ -19,7 +19,7 @@ export function getCookie(name: string) { const value = "; " + document.cookie; const parts = value.split("; " + name + "="); - if (parts.length == 2) { + if (parts.length === 2) { return parts.pop()?.split(";").shift(); } } diff --git a/tools/scripts/client/build.sh b/tools/scripts/client/build.sh index d751b2da..365cb569 100755 --- a/tools/scripts/client/build.sh +++ b/tools/scripts/client/build.sh @@ -10,7 +10,9 @@ if [ -z "$1" ]; then echo -e "\033[0;33mNo stage provided. 'local' stage will be used.\033[0m" fi +echo "kek" export SERVER_API_URL="$(grep -w SERVER_API_URL "./tools/docker/env/$stage.env" | cut -d '=' -f2-)" # extract env variable by key +echo "SERVER_API_URL: '${SERVER_API_URL}'" (cd "$rootDir" && npm --prefix "$rootDir/client" run build) echo -e "\033[0;32mClient has been built.\033[0m"