Skip to content

Commit

Permalink
Merge pull request #159 from AII-the-time/develop
Browse files Browse the repository at this point in the history
[release] v3.1.1
  • Loading branch information
915dbfl authored Nov 12, 2023
2 parents e3a8032 + baee47b commit 8964a62
Show file tree
Hide file tree
Showing 7 changed files with 79 additions and 13 deletions.
41 changes: 38 additions & 3 deletions .github/workflows/android-cd.yml
Original file line number Diff line number Diff line change
@@ -1,22 +1,57 @@
name: Android CD

on:
push:
branches: [ main ]
workflow_run:
workflows: [Android CI]
types: [completed]
branches: [develop]

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Gradle cache
uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: set up JDK 17
uses: actions/setup-java@v3
with:
java-version: 17
distribution: 'zulu'

- name: Generate Local Property
run: |
echo ATT_BASE_URL=\"$ATT_BASE_URL\" >> local.properties
echo SENTRY_DSN_DEBUG=\"SENTRY_DSN_DEBUG\" >> local.properties
echo SENTRY_DSN_RELEASE=\"SENTRY_DSN_RELEASE\" >> local.properties
env:
ATT_BASE_URL: ${{ secrets.ATT_BASE_URL }}
SENTRY_DSN_DEBUG: ${{ secrets.SENTRY_DSN_DEBUG }}
SENTRY_DSN_RELEASE: ${{ secrets.SENTRY_DSN_RELEASE }}

- name: Grant execute permission for gradlew
run: chmod +x gradlew

- name: Build debug apk
run: ./gradlew assembleDebug --stacktrace

- name: Upload apk to Firebase App Distribution
uses: wzieba/Firebase-Distribution-Github-Action@v1
with:
appId: ${{ secrets.FIREBASE_APP_ID }}
serviceCredentialsFileContent: ${{ secrets.CREDENTIAL_FILE_CONTENT }}
token: ${{ secrets.FIREBASE_TOKEN }}
groups: all-the-time
file: app/build/outputs/apk/debug/app-debug.apk
releaseNotes: |
${{ github.event.pull_request.title }}
${{ github.event.pull_request.html_url }}
${{ github.event.pull_request.body }}
14 changes: 8 additions & 6 deletions .github/workflows/android-ci.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
name: Android CI

on:
push:
branches: [ develop ]
pull_request:

defaults:
run:
shell: bash
working-directory: .

jobs:
build-and-test:
Expand All @@ -19,6 +23,7 @@ jobs:
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: set up JDK 17
uses: actions/setup-java@v3
with:
Expand All @@ -43,7 +48,4 @@ jobs:

- name: Android Test Report
uses: asadmansr/[email protected]
if: ${{ always() }}

- name: Build debug apk
run: ./gradlew assembleDebug --stacktrace
if: ${{ always() }}
3 changes: 0 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,6 @@ render.experimental.xml
*.jks
*.keystore

# Google Services (e.g. APIs or Firebase)
google-services.json

# Android Profiling
*.hprof

Expand Down
1 change: 1 addition & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ plugins {
id("androidx.navigation.safeargs.kotlin")
id("dagger.hilt.android.plugin")
id("com.google.android.libraries.mapsplatform.secrets-gradle-plugin")
id("com.google.gms.google-services")
kotlin("kapt")
}

Expand Down
29 changes: 29 additions & 0 deletions app/google-services.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{
"project_info": {
"project_number": "92675282109",
"project_id": "att-cafe-pos",
"storage_bucket": "att-cafe-pos.appspot.com"
},
"client": [
{
"client_info": {
"mobilesdk_app_id": "1:92675282109:android:149bc9908ab09490c653d4",
"android_client_info": {
"package_name": "org.swm.att"
}
},
"oauth_client": [],
"api_key": [
{
"current_key": "AIzaSyAu1PwxGiRoPpaBt77NjfrVG2MQJgAOO6A"
}
],
"services": {
"appinvite_service": {
"other_platform_oauth_client": []
}
}
}
],
"configuration_version": "1"
}
1 change: 1 addition & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,5 @@ plugins {
alias(libs.plugins.dagger.hilt) apply false
alias(libs.plugins.secret) apply false
alias(libs.plugins.kotlin.serialization) apply false
alias(libs.plugins.google.services) apply false
}
3 changes: 2 additions & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -117,4 +117,5 @@ kotlin-android = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin_an
navigation_safeargs = { id = "androidx.navigation.safeargs.kotlin", version.ref = "navigation" }
dagger_hilt = { id = "com.google.dagger.hilt.android", version.ref = "dagger-hilt" }
secret = { id = "com.google.android.libraries.mapsplatform.secrets-gradle-plugin", version.ref = "secret" }
kotlin-serialization = { id = "org.jetbrains.kotlin.plugin.serialization", version.ref = "kotlin" }
kotlin-serialization = { id = "org.jetbrains.kotlin.plugin.serialization", version.ref = "kotlin" }
google-services = { id = "com.google.gms.google-services", version.ref = "google-services" }

0 comments on commit 8964a62

Please sign in to comment.