From e3de158d188d094b9aad8ed9816584865b9dd9a6 Mon Sep 17 00:00:00 2001 From: Laurent Cozic Date: Thu, 21 Mar 2024 15:51:01 +0000 Subject: [PATCH] Tools: Fixed building macOS app on CI --- .github/scripts/run_ci.sh | 48 +++++++++++++++------------------------ 1 file changed, 18 insertions(+), 30 deletions(-) diff --git a/.github/scripts/run_ci.sh b/.github/scripts/run_ci.sh index 5441a213b..4e55fa43e 100755 --- a/.github/scripts/run_ci.sh +++ b/.github/scripts/run_ci.sh @@ -19,12 +19,6 @@ if [ "$GITHUB_EVENT_NAME" == "pull_request" ]; then IS_PULL_REQUEST=1 fi -# In some case it might not be possible to detect if we're on a pull request, for example when -# pushing new code to an existing code (or maybe when pressing "Update branch" from GitHub). In that -# case "GITHUB_EVENT_NAME" is "push" it's not clear what else could be checked. It seems safe to -# always run the checks anyway so we do this for now. -IS_PULL_REQUEST=1 - if [[ $GIT_TAG_NAME = $SERVER_TAG_PREFIX-* ]]; then IS_SERVER_RELEASE=1 fi @@ -147,15 +141,13 @@ fi # for Linux only is sufficient. # ============================================================================= -if [ "$IS_PULL_REQUEST" == "1" ]; then - if [ "$IS_LINUX" == "1" ]; then - echo "Step: Validating translations..." +if [ "$IS_LINUX" == "1" ]; then + echo "Step: Validating translations..." - node packages/tools/validate-translation.js - testResult=$? - if [ $testResult -ne 0 ]; then - exit $testResult - fi + node packages/tools/validate-translation.js + testResult=$? + if [ $testResult -ne 0 ]; then + exit $testResult fi fi @@ -185,15 +177,13 @@ fi # See coding_style.md # ============================================================================= -if [ "$IS_PULL_REQUEST" == "1" ]; then - if [ "$IS_LINUX" == "1" ]; then - echo "Step: Checking for files that should have been ignored..." +if [ "$IS_LINUX" == "1" ]; then + echo "Step: Checking for files that should have been ignored..." - node packages/tools/checkIgnoredFiles.js - testResult=$? - if [ $testResult -ne 0 ]; then - exit $testResult - fi + node packages/tools/checkIgnoredFiles.js + testResult=$? + if [ $testResult -ne 0 ]; then + exit $testResult fi fi @@ -219,15 +209,13 @@ fi # Spellchecking # ============================================================================= -if [ "$IS_PULL_REQUEST" == "1" ]; then - if [ "$IS_LINUX" == "1" ]; then - echo "Step: Spellchecking..." +if [ "$IS_LINUX" == "1" ]; then + echo "Step: Spellchecking..." - yarn spellcheck --all - testResult=$? - if [ $testResult -ne 0 ]; then - exit $testResult - fi + yarn spellcheck --all + testResult=$? + if [ $testResult -ne 0 ]; then + exit $testResult fi fi