From 6938b1bfa814d2dcae25585446de8aa9d1669db2 Mon Sep 17 00:00:00 2001 From: Kirill Taran Date: Fri, 20 Jan 2023 09:01:04 +0300 Subject: [PATCH] CI enhancements --- .github/workflows/build.yml | 32 ++++++++++++++++---------------- .github/workflows/release.yml | 3 +++ app/build.gradle | 4 +++- 3 files changed, 22 insertions(+), 17 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 6ede4b392..f0c92a42e 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -11,23 +11,23 @@ jobs: ACRA_PASS: ${{ secrets.ACRARIUM_BASIC_AUTH_PASSWORD }} ACRA_URI: ${{ secrets.ACRARIUM_URI }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v3 - - name: set up JDK 11 - uses: actions/setup-java@v3 - with: - java-version: '11' - distribution: 'adopt' - cache: gradle + - name: set up JDK 11 + uses: actions/setup-java@v3 + with: + java-version: '11' + distribution: 'adopt' + cache: gradle - - name: Grant execute permission for gradlew - run: chmod +x gradlew + - name: Validate Gradle wrapper + uses: gradle/wrapper-validation-action@v1.0.5 - - name: Build Release APK - run: ./gradlew assembleRelease + - name: Build Release APK + run: ./gradlew assembleRelease - - name: Upload Release APK - uses: actions/upload-artifact@v3 - with: - name: release-apk - path: ./app/build/outputs/apk/release/app-release.apk + - name: Upload Release APK + uses: actions/upload-artifact@v3 + with: + name: ark-rate-release + path: ./app/build/outputs/apk/release/ark-rate-release.apk diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 53b68e600..790ca8d4b 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -23,6 +23,9 @@ jobs: java-version: '11' distribution: 'adopt' + - name: Validate Gradle wrapper + uses: gradle/wrapper-validation-action@v1.0.5 + - name: Build Release APK run: ./gradlew assembleRelease diff --git a/app/build.gradle b/app/build.gradle index a07bd4547..9010d53c0 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -13,6 +13,8 @@ android { targetSdk 33 versionCode 1 versionName "1.0" + setProperty("archivesBaseName", "ark-rate") + def login = System.getenv("ACRA_LOGIN") ?: "" def password = System.getenv("ACRA_PASS") ?: "" def uri = System.getenv("ACRA_URI") ?: "" @@ -104,4 +106,4 @@ dependencies { implementation 'ch.acra:acra-http:5.9.6' implementation 'ch.acra:acra-dialog:5.9.6' implementation 'com.github.SimpleMobileTools:Simple-Commons:7e0240b1e3' -} \ No newline at end of file +}