File tree Expand file tree Collapse file tree 4 files changed +38
-6
lines changed
Expand file tree Collapse file tree 4 files changed +38
-6
lines changed Original file line number Diff line number Diff line change 1818jobs :
1919 build-activity-demo :
2020 runs-on : ubuntu-latest
21+ strategy :
22+ matrix :
23+ java-version : [11, 17, 21]
24+ include :
25+ - java-version : 11
26+ gradle-version : 6.5
27+ agp-version : 4.1.3
28+ - java-version : 17
29+ gradle-version : 7.5
30+ agp-version : 7.4.2
31+ - java-version : 21
32+ gradle-version : 8.5
33+ agp-version : 8.2.2
34+
2135 defaults :
2236 run :
2337 working-directory : demo/android/Activity
2438
2539 steps :
2640 - uses : actions/checkout@v3
41+
42+ - name : Override gradle settings
43+ run : sed -i "s/com.android.tools.build:gradle:[0-9]*\.[0-9]*\.[0-9]*/com.android.tools.build:gradle:${{ matrix.agp-version }}/g" build.gradle
2744
28- - name : set up JDK 17
45+ - name : set up JDK ${{ matrix.java-version }}
2946 uses : actions/setup-java@v3
3047 with :
31- java-version : ' 17 '
48+ java-version : ${{ matrix.java-version }}
3249 distribution : ' temurin'
50+
51+ - name : Use Gradle ${{ matrix.gradle-version }}
52+ uses : gradle/actions/setup-gradle@v3
53+ with :
54+ gradle-version : ${{ matrix.gradle-version }}
55+
3356
3457 - name : Build
35- run : ./gradlew assembleDebug
58+ run : gradle assembleDebug
Original file line number Diff line number Diff line change @@ -15,3 +15,5 @@ org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8
1515# Android operating system, and which are packaged with your app"s APK
1616# https://developer.android.com/topic/libraries/support-library/androidx-rn
1717android.useAndroidX =true
18+ android.nonTransitiveRClass =false
19+
Original file line number Diff line number Diff line change 11apply plugin : ' com.android.application'
22
33android {
4+ def agpVersion = com.android.Version . ANDROID_GRADLE_PLUGIN_VERSION
45 compileSdk defaultTargetSdkVersion
56
67 defaultConfig {
@@ -18,14 +19,19 @@ android {
1819 proguardFiles getDefaultProguardFile(' proguard-android-optimize.txt' ), ' proguard-rules.pro'
1920 }
2021 }
22+ buildFeatures {
23+ buildConfig true
24+ }
2125 compileOptions {
2226 sourceCompatibility JavaVersion . VERSION_1_8
2327 targetCompatibility JavaVersion . VERSION_1_8
2428 }
25- lint {
29+ lintOptions {
2630 abortOnError false
2731 }
28- namespace ' ai.picovoice.koalaactivitydemo'
32+ if (agpVersion. tokenize(' .' )[0 ]. toInteger() >= 7 ) {
33+ namespace ' ai.picovoice.koalaactivitydemo'
34+ }
2935}
3036
3137dependencies {
Original file line number Diff line number Diff line change 11<?xml version =" 1.0" encoding =" utf-8" ?>
2- <manifest xmlns : android =" http://schemas.android.com/apk/res/android" >
2+ <manifest xmlns : android =" http://schemas.android.com/apk/res/android"
3+ package =" ai.picovoice.koalaactivitydemo" >
34
45 <uses-permission android : name =" android.permission.INTERNET" />
56 <uses-permission android : name =" android.permission.RECORD_AUDIO" />
You can’t perform that action at this time.
0 commit comments