From d40cfe0e98aca62fef20be263ac5dc5b80e1b31f Mon Sep 17 00:00:00 2001 From: Benoit Marty Date: Thu, 20 Jul 2023 11:07:08 +0200 Subject: [PATCH 1/2] Do not build main branch in this workflow. --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 7d895d0fda..962405e782 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -4,7 +4,7 @@ on: workflow_dispatch: pull_request: { } push: - branches: [ main, develop ] + branches: [ develop ] # Enrich gradle.properties for CI/CD env: From 05f2af39305659b81dd1621cca3f40058405c116 Mon Sep 17 00:00:00 2001 From: Benoit Marty Date: Thu, 20 Jul 2023 11:08:09 +0200 Subject: [PATCH 2/2] Add workflow to create app bundle. --- .github/workflows/release.yml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000000..6e6e383604 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,31 @@ +name: Create release App Bundle + +on: + workflow_dispatch: + push: + branches: [ main ] + +# Enrich gradle.properties for CI/CD +env: + GRADLE_OPTS: -Dorg.gradle.jvmargs="-Xmx3072m -Dfile.encoding=UTF-8 -XX:+HeapDumpOnOutOfMemoryError" -Dkotlin.daemon.jvm.options="-Xmx2560m" -Dkotlin.incremental=false + CI_GRADLE_ARG_PROPERTIES: --stacktrace -PpreDexEnable=false --max-workers 2 --no-daemon + +jobs: + release: + name: Create App Bundle + runs-on: ubuntu-latest + concurrency: + group: ${{ github.ref == 'refs/head/main' && format('build-release-main-{0}', github.sha) }} + cancel-in-progress: true + steps: + - uses: actions/checkout@v3 + - name: Configure gradle + uses: gradle/gradle-build-action@v2.6.1 + - name: Create app bundle + run: ./gradlew bundleRelease $CI_GRADLE_ARG_PROPERTIES + - name: Upload bundle as artifact + uses: actions/upload-artifact@v3 + with: + name: elementx-app-bundle-unsigned + path: | + app/build/outputs/bundle/release/app-release.aab