Skip to content

Commit

Permalink
NEVISACCESSAPP-5853: Updated Android configuration to use Gradle 8.4.…
Browse files Browse the repository at this point in the history
…0 and above and AGP 8.3.0 and above (#53)
  • Loading branch information
laszlo-domonkos authored Oct 4, 2024
1 parent 89f80c4 commit 452be88
Show file tree
Hide file tree
Showing 11 changed files with 26 additions and 24 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/develop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ env:
BUILD_TYPE: 'SNAPSHOT' # Allowed values: 'SNAPSHOT', 'RELEASE', 'RELEASE_CANDIDATE'
FLUTTER_VERSION: '3.19.0'
XCODE_VERSION: '15.4'
JAVA_VERSION: '11'
JAVA_VERSION: '17'
RUBY_VERSION: '3.1'
HOST_NAME: ${{ secrets.HOST_NAME }}
PRIVATE_REPOSITORY_API_KEY: ${{ secrets.PRIVATE_REPOSITORY_API_KEY }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ env:
BUILD_TYPE: 'RELEASE' # Allowed values: 'SNAPSHOT', 'RELEASE', 'RELEASE_CANDIDATE'
FLUTTER_VERSION: '3.19.0'
XCODE_VERSION: '15.4'
JAVA_VERSION: '11'
JAVA_VERSION: '17'
RUBY_VERSION: '3.1'
HOST_NAME: ${{ secrets.HOST_NAME }}
PRIVATE_REPOSITORY_API_KEY: ${{ secrets.PRIVATE_REPOSITORY_API_KEY }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ env:
BUILD_TYPE: 'SNAPSHOT' # Allowed values: 'SNAPSHOT', 'RELEASE', 'RELEASE_CANDIDATE'
FLUTTER_VERSION: '3.19.0'
XCODE_VERSION: '15.4'
JAVA_VERSION: '11'
JAVA_VERSION: '17'
RUBY_VERSION: '3.1'
HOST_NAME: ${{ secrets.HOST_NAME }}
PRIVATE_REPOSITORY_API_KEY: ${{ secrets.PRIVATE_REPOSITORY_API_KEY }}
Expand Down Expand Up @@ -107,4 +107,4 @@ jobs:
uses: maierj/[email protected]
with:
lane: 'pr'
subdirectory: 'android'
subdirectory: 'android'
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ env:
BUILD_TYPE: 'RELEASE_CANDIDATE' # Allowed values: 'SNAPSHOT', 'RELEASE', 'RELEASE_CANDIDATE'
FLUTTER_VERSION: '3.19.0'
XCODE_VERSION: '15.4'
JAVA_VERSION: '11'
JAVA_VERSION: '17'
RUBY_VERSION: '3.1'
HOST_NAME: ${{ secrets.HOST_NAME }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down Expand Up @@ -93,4 +93,4 @@ jobs:
uses: maierj/[email protected]
with:
lane: 'pr'
subdirectory: 'android'
subdirectory: 'android'
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,11 @@ Your development setup has to meet the following prerequisites:
* Xcode 15.x, including Swift 5.7 or later
* Android 6 or later, with API level 23 -or-
* Android 10 or later, with API level 29, for the biometric authenticator to work
* Gradle 7.4 or later
* Android Gradle Plugin `com.android.tools.build:gradle` 7.0.0 or later
* Kotlin Gradle Plugin `org.jetbrains.kotlin:kotlin-gradle-plugin` 1.8.0 or later
* Gradle 8.4 or later
* Android Gradle Plugin `com.android.tools.build:gradle` 8.3.0 or later
* Kotlin Gradle Plugin `org.jetbrains.kotlin:kotlin-gradle-plugin` 1.8.22 or later
* Dart SDK 3.3.0 or later
* Java 17

### Initialization

Expand Down
12 changes: 7 additions & 5 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -30,14 +30,15 @@ apply plugin: 'kotlin-android'
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"

android {
compileSdkVersion 34
namespace 'ch.nevis.nevis_mobile_authentication_sdk_example_app_flutter'
compileSdk 34
compileOptions {
sourceCompatibility JavaVersion.VERSION_11
targetCompatibility JavaVersion.VERSION_11
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
}

kotlinOptions {
jvmTarget = '11'
jvmTarget = '17'
}

sourceSets {
Expand All @@ -47,7 +48,8 @@ android {
defaultConfig {
applicationId "ch.nevis.nevis_mobile_authentication_sdk_example"
minSdkVersion 23
targetSdkVersion flutter.targetSdkVersion
targetSdkVersion 34
multiDexEnabled true
versionCode flutterVersionCode.toInteger()
versionName flutterVersionName
}
Expand Down
3 changes: 1 addition & 2 deletions android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="ch.nevis.nevis_mobile_authentication_sdk_example_app_flutter">
<manifest xmlns:android="http://schemas.android.com/apk/res/android">

<uses-permission android:name="android.permission.INTERNET" />

Expand Down
3 changes: 1 addition & 2 deletions android/app/src/profile/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="ch.nevis.nevis_mobile_authentication_sdk_example_app_flutter">
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
<!-- The INTERNET permission is required for development. Specifically,
the Flutter tool needs it to communicate with the running application
to allow setting breakpoints, to provide hot reload, etc.
Expand Down
4 changes: 2 additions & 2 deletions android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
*/

buildscript {
ext.gradle_version = '7.2.2'
ext.kotlin_version = '1.8.0'
ext.gradle_version = '8.3.0'
ext.kotlin_version = '1.8.22'

repositories {
google()
Expand Down
4 changes: 2 additions & 2 deletions android/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@
org.gradle.jvmargs=-Xmx1536M
android.useAndroidX=true
android.enableJetifier=true
android.enableDexingArtifactTransform=false
shrink=false
android.useFullClasspathForDexingTransform=true
shrink=false
5 changes: 3 additions & 2 deletions android/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#Fri Jun 23 08:50:38 CEST 2017
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists

0 comments on commit 452be88

Please sign in to comment.