lmw
2025-05-29 855a7e18a795f0db2453a19e3e8f26ba2ff553b4
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
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
 
android {
    compileSdkVersion 30
    buildToolsVersion "29.0.3"
 
    defaultConfig {
        applicationId "com.dollearn.student"
        minSdkVersion 21
        targetSdkVersion 30
        versionCode 1
        versionName "1.0"
        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
    }
 
    //签名
    signingConfigs {
        release {
            storeFile file("dollearn.jks")
            storePassword "sinata"
            keyAlias "dollearn"
            keyPassword "sinata"
        }
    }
 
    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }
 
    //netty 必须屏蔽这几个文件
    packagingOptions {
        exclude 'META-INF/NOTICE' // will not include NOTICE file
        exclude 'META-INF/LICENSE' // will not include LICENSE file
        //netty files
        exclude 'META-INF/INDEX.LIST' // will not include this file
        exclude 'META-INF/io.netty.versions.properties' // will not include this file
    }
 
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
 
            applicationVariants.all { variant ->
                // 更新至Android Studio 3.3 gradle 4.10.1
                variant.outputs.all {
                    outputFileName = "dollearn-${defaultConfig.versionName}-${new Date().format("yyyy-MM-dd" , TimeZone.getTimeZone("GMT+08")) }.apk"
                }
            }
//            ndk {
//                abiFilters "armeabi-v7a","arm64-v8a" // 保留这种架构的CPU
//            }
        }
 
        debug {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
            signingConfig signingConfigs.release
//            ndk {
//                abiFilters "armeabi-v7a" ,"arm64-v8a" // 保留这种架构的CPU
//            }
        }
    }
 
    sourceSets {
        main {
            jniLibs.srcDirs = ['libs']
        }
    }
 
}
 
repositories {
    // 支付宝 SDK AAR 包所需的配置
    flatDir {
        dirs 'libs','../umeng_sdk/libs'
    }
}
 
dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
    implementation "androidx.appcompat:appcompat:$androidx_version"
    implementation 'androidx.core:core-ktx:1.3.0'
    implementation 'androidx.constraintlayout:constraintlayout:2.0.4'
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'androidx.test.ext:junit:1.1.1'
    androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
    implementation project(path: ':xldutils-kotlin')
    implementation 'com.google.android.material:material:1.2.1'
    implementation 'com.github.PhilJay:MPAndroidChart:v3.1.0'
    implementation 'com.youth.banner:banner:2.0.11'
    implementation project(path: ':umeng_sdk')
    implementation 'top.zibin:Luban:1.1.8'//图片压缩
    implementation 'com.github.dueeeke.dkplayer:dkplayer-java:3.2.6'
    implementation 'com.github.dueeeke.dkplayer:dkplayer-ui:3.2.6'
//    implementation 'com.github.dueeeke.dkplayer:player-ijk:3.2.6' //可选,使用ijkplayer进行解码
    implementation 'com.haibin:calendarview:3.6.9'//日历
    implementation 'cn.bingoogolapple:bga-qrcode-zxing:1.3.7'//二维码
    implementation 'com.github.bumptech.glide:glide:4.11.0'//必须集成
    annotationProcessor 'com.github.bumptech.glide:compiler:4.10.0'
    implementation 'com.aliyun.dpa:oss-android-sdk:2.9.2'
    implementation 'com.scwang.smart:refresh-layout-kernel:2.0.3'
    implementation 'com.scwang.smart:refresh-header-classics:2.0.3'    //经典刷新头
    implementation 'com.scwang.smart:refresh-header-material:2.0.3' //谷歌刷新头
    implementation 'com.github.promeg:tinypinyin:2.0.3'
}