build.gradle
2.21 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
plugins {
id "com.android.application"
id "kotlin-android"
id "kotlin-kapt"
// The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
id "dev.flutter.flutter-gradle-plugin"
}
def flutterVersionCode = null
def flutterVersionName = null
if (flutter.hasProperty('versionCode')) {
flutterVersionCode = flutter.versionCode
}
if (flutter.hasProperty('versionName')) {
flutterVersionName = flutter.versionName
}
if (flutterVersionCode == null || flutterVersionName == null) {
def localProperties = new Properties()
rootProject.file('local.properties').withReader('UTF-8') { reader ->
localProperties.load(reader)
}
if (flutterVersionCode == null) {
flutterVersionCode = localProperties.getProperty('flutter.versionCode')
}
if (flutterVersionName == null) {
flutterVersionName = localProperties.getProperty('flutter.versionName')
}
}
android {
namespace "com.fluttercandies.wechatAssetsPickerExample"
compileSdk flutter.compileSdkVersion
ndkVersion flutter.ndkVersion
defaultConfig {
applicationId = "com.fluttercandies.wechatAssetsPickerExample"
minSdk 21
targetSdk flutter.targetSdkVersion
versionCode flutterVersionCode.toInteger()
versionName flutterVersionName
}
sourceSets {
main.java.srcDirs += 'src/main/kotlin'
}
kotlinOptions {
jvmTarget = '17'
}
compileOptions {
// Sets Java compatibility to Java 17
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
}
signingConfigs {
forAll {
storeFile file("${rootDir.absolutePath}/key.jks")
storePassword 'picker'
keyAlias 'picker'
keyPassword 'picker'
}
}
buildTypes {
debug {
signingConfig signingConfigs.forAll
}
profile {
signingConfig signingConfigs.forAll
}
release {
signingConfig signingConfigs.forAll
}
}
}
flutter {
source '../..'
}
dependencies {
implementation 'com.github.bumptech.glide:glide:4.15.0'
kapt 'com.github.bumptech.glide:compiler:4.15.0'
}