From 29bddbd3ef5a2eac7c5a5508be78fc7e55f69136 Mon Sep 17 00:00:00 2001 From: Codel1417 <13484789+Codel1417@users.noreply.github.com> Date: Fri, 12 Apr 2024 16:01:08 -0400 Subject: [PATCH] build debug version for PR --- .github/workflows/build_apk.yml | 1 + Scripts/build.sh | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build_apk.yml b/.github/workflows/build_apk.yml index 7e3340fa..c8e5249f 100644 --- a/.github/workflows/build_apk.yml +++ b/.github/workflows/build_apk.yml @@ -56,6 +56,7 @@ jobs: working-directory: Scripts env: RELEASE_TAG: ${{ github.event.release.tag_name }} + GITHUB_EVENT_NAME: ${{ github.event_name }} - uses: actions/upload-artifact@v4 with: path: | diff --git a/Scripts/build.sh b/Scripts/build.sh index 2f369cce..b3beb161 100644 --- a/Scripts/build.sh +++ b/Scripts/build.sh @@ -16,10 +16,14 @@ fi flutter config --no-cli-animations flutter pub get flutter gen-l10n +DEBUG="" +if [[ 'pull_request' == GITHUB_EVENT_NAME ]]; then + DEBUG="--debug" +fi dart run intl_translation:generate_from_arb --output-dir=lib/l10n --no-use-deferred-loading lib/Frontend/intn_defs.dart lib/l10n/*.arb flutter pub run build_runner build --delete-conflicting-outputs if [[ ! -v SKIP_BUILD ]]; then - flutter build apk --split-debug-info=./symbols --build-number="$BUILD_NUMBER" --build-name="$VERSION" + flutter build apk --split-debug-info=./symbols $DEBUG --build-number="$BUILD_NUMBER" --build-name="$VERSION" flutter build appbundle --split-debug-info=./symbols --build-number="$BUILD_NUMBER" --build-name="$VERSION" if [[ -v GITHUB_OUTPUT ]]; then echo "SENTRY_DIST=$BUILD_NUMBER" >> "$GITHUB_OUTPUT"