plugins { id 'com.android.library' id 'org.jetbrains.kotlin.android' } android { compileSdk 32 defaultConfig { minSdk 21 targetSdk 32 versionCode 1 versionName "1.0" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" consumerProguardFiles "consumer-rules.pro" } buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' } } compileOptions { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 } } dependencies { implementation 'androidx.appcompat:appcompat:1.2.0' implementation 'com.google.android.material:material:1.3.0' implementation 'androidx.core:core-ktx:+' implementation 'androidx.lifecycle:lifecycle-viewmodel-ktx:2.0.0' testImplementation 'junit:junit:4.+' androidTestImplementation 'androidx.test.ext:junit:1.1.2' androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0' api fileTree(include: ['*.jar'], dir: 'libs') //support api rootProject.ext.support["support-v4"] api rootProject.ext.support["appcompat-v7"] api rootProject.ext.support["recyclerview-v7"] //rxjava api rootProject.ext.dependencies.rxjava api rootProject.ext.dependencies.rxandroid //rx管理View的生命周期 api(rootProject.ext.dependencies.rxlifecycle) { exclude group: 'com.android.support' } api(rootProject.ext.dependencies["rxlifecycle-components"]) { exclude group: 'com.android.support' } //rxbinding api(rootProject.ext.dependencies.rxbinding) { exclude group: 'com.android.support' } //rx权限请求 api(rootProject.ext.dependencies.rxpermissions) { exclude group: 'com.android.support' } // implementation 'com.github.tbruyelle:rxpermissions:0.12' //network api rootProject.ext.dependencies.okhttp api rootProject.ext.dependencies.retrofit api rootProject.ext.dependencies["converter-gson"] api rootProject.ext.dependencies["adapter-rxjava"] //json解析 api rootProject.ext.dependencies.gson //material-dialogs api(rootProject.ext.dependencies["material-dialogs-core"]) { exclude group: 'com.android.support' } api(rootProject.ext.dependencies["material-dialogs-commons"]) { exclude group: 'com.android.support' } //glide图片加载库 api (rootProject.ext.dependencies.glide){ exclude group: 'com.android.support' } implementation 'androidx.recyclerview:recyclerview:1.1.0' annotationProcessor rootProject.ext.dependencies["glide-compiler"] //recyclerview的databinding套装 api(rootProject.ext.dependencies.bindingcollectionadapter) { exclude group: 'com.android.support' } api(rootProject.ext.dependencies["bindingcollectionadapter-recyclerview"]) { exclude group: 'com.android.support' } //Google LiveData和ViewModel组件 api rootProject.ext.dependencies["lifecycle-extensions"] annotationProcessor rootProject.ext.dependencies["lifecycle-compiler"] api rootProject.ext.dependencies["fastjson"] // implementation 'com.google.android.gms:play-services-ads:19.4.0' implementation 'com.google.android.gms:play-services-ads-identifier:17.0.0' }