Skip to content

Commit c2fe29a

Browse files
authored
feat(battery_plus)!: Change Android compile SDK, update Android build config (#3666)
1 parent d0fdc58 commit c2fe29a

File tree

6 files changed

+13
-20
lines changed

6 files changed

+13
-20
lines changed

packages/battery_plus/battery_plus/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@ A Flutter plugin to access various information about the battery of the device t
2020
- Dart >=3.4.0 <4.0.0
2121
- iOS >=12.0
2222
- macOS >=10.14
23-
- Android `compileSDK` 34
2423
- Java 17
25-
- Android Gradle Plugin >=8.3.0
26-
- Gradle wrapper >=8.4
24+
- Kotlin 2.2.0
25+
- Android Gradle Plugin >=8.12.1
26+
- Gradle wrapper >=8.13
2727

2828
## Usage
2929

packages/battery_plus/battery_plus/android/build.gradle

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,14 @@ group 'dev.fluttercommunity.plus.battery'
22
version '1.0-SNAPSHOT'
33

44
buildscript {
5-
ext.kotlin_version = '1.7.22'
5+
ext.kotlin_version = '2.2.0'
66
repositories {
77
google()
88
mavenCentral()
99
}
1010

1111
dependencies {
12-
classpath 'com.android.tools.build:gradle:8.3.1'
12+
classpath 'com.android.tools.build:gradle:8.12.1'
1313
}
1414
}
1515

@@ -24,9 +24,8 @@ apply plugin: 'com.android.library'
2424
apply plugin: 'kotlin-android'
2525

2626
android {
27-
compileSdk 34
28-
2927
namespace 'dev.fluttercommunity.plus.battery'
28+
compileSdk = flutter.compileSdkVersion
3029

3130
compileOptions {
3231
sourceCompatibility JavaVersion.VERSION_17
@@ -49,5 +48,5 @@ android {
4948

5049
dependencies {
5150
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
52-
implementation "androidx.core:core-ktx:1.13.1"
51+
implementation "androidx.core:core-ktx:1.16.0"
5352
}

packages/battery_plus/battery_plus/android/gradle/wrapper/gradle-wrapper.properties

Lines changed: 0 additions & 5 deletions
This file was deleted.

packages/battery_plus/battery_plus/example/android/app/build.gradle

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,8 @@ if (flutterVersionName == null) {
2323
}
2424

2525
android {
26-
compileSdk 34
27-
2826
namespace 'io.flutter.plugins.batteryexample.example'
27+
compileSdk = flutter.compileSdkVersion
2928

3029
compileOptions {
3130
sourceCompatibility JavaVersion.VERSION_17
@@ -47,8 +46,8 @@ android {
4746
defaultConfig {
4847
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
4948
applicationId "io.flutter.plugins.batteryexample.example"
50-
minSdk 21
51-
targetSdk 34
49+
minSdk flutter.minSdkVersion
50+
targetSdk flutter.targetSdkVersion
5251
versionCode flutterVersionCode.toInteger()
5352
versionName flutterVersionName
5453
}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#Tue Oct 05 14:03:03 CEST 2021
22
distributionBase=GRADLE_USER_HOME
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-bin.zip
44
distributionPath=wrapper/dists
55
zipStorePath=wrapper/dists
66
zipStoreBase=GRADLE_USER_HOME

packages/battery_plus/battery_plus/example/android/settings.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ pluginManagement {
1818

1919
plugins {
2020
id "dev.flutter.flutter-plugin-loader" version "1.0.0"
21-
id "com.android.application" version "8.3.1" apply false
22-
id "org.jetbrains.kotlin.android" version "1.9.23" apply false
21+
id "com.android.application" version "8.12.1" apply false
22+
id "org.jetbrains.kotlin.android" version "2.2.0" apply false
2323
}
2424

2525
include ":app"

0 commit comments

Comments
 (0)