82 lines
2.9 KiB
Groovy
82 lines
2.9 KiB
Groovy
apply plugin: 'com.android.application'
|
||
apply from: '../.winboll/winboll_app_build.gradle'
|
||
apply from: '../.winboll/winboll_lint_build.gradle'
|
||
|
||
def genVersionName(def versionName){
|
||
// 检查编译标志位配置
|
||
assert (winbollBuildProps['stageCount'] != null)
|
||
assert (winbollBuildProps['baseVersion'] != null)
|
||
// 保存基础版本号
|
||
winbollBuildProps.setProperty("baseVersion", "${versionName}");
|
||
//保存编译标志配置
|
||
FileOutputStream fos = new FileOutputStream(winbollBuildPropsFile)
|
||
winbollBuildProps.store(fos, "${winbollBuildPropsDesc}");
|
||
fos.close();
|
||
|
||
// 返回编译版本号
|
||
return "${versionName}." + winbollBuildProps['stageCount']
|
||
}
|
||
|
||
android {
|
||
compileSdkVersion 30
|
||
buildToolsVersion "30.0.3"
|
||
|
||
defaultConfig {
|
||
applicationId "cc.winboll.studio.contacts"
|
||
minSdkVersion 26
|
||
targetSdkVersion 29
|
||
versionCode 1
|
||
// versionName 更新后需要手动设置
|
||
// 项目模块目录的 build.gradle 文件的 stageCount=0
|
||
// Gradle编译环境下合起来的 versionName 就是 "${versionName}.0"
|
||
versionName "1.0"
|
||
if(true) {
|
||
versionName = genVersionName("${versionName}")
|
||
}
|
||
}
|
||
|
||
buildTypes {
|
||
release {
|
||
minifyEnabled false
|
||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
|
||
}
|
||
}
|
||
}
|
||
|
||
dependencies {
|
||
api fileTree(dir: 'libs', include: ['*.jar'])
|
||
|
||
// 权限请求框架:https://github.com/getActivity/XXPermissions
|
||
implementation 'com.github.getActivity:XXPermissions:18.63'
|
||
// 下拉控件
|
||
implementation 'com.baoyz.pullrefreshlayout:library:1.2.0'
|
||
// 拼音搜索
|
||
// https://mvnrepository.com/artifact/com.github.open-android/pinyin4j
|
||
implementation 'com.github.open-android:pinyin4j:2.5.0'
|
||
// SSH
|
||
implementation 'com.jcraft:jsch:0.1.55'
|
||
// Html 解析
|
||
implementation 'org.jsoup:jsoup:1.13.1'
|
||
// 二维码类库
|
||
implementation 'com.google.zxing:core:3.4.1'
|
||
implementation 'com.journeyapps:zxing-android-embedded:3.6.0'
|
||
// 应用介绍页类库
|
||
implementation 'io.github.medyo:android-about-page:2.0.0'
|
||
// 吐司类库
|
||
implementation 'com.github.getActivity:ToastUtils:10.5'
|
||
// 网络连接类库
|
||
implementation 'com.squareup.okhttp3:okhttp:4.4.1'
|
||
|
||
// Android 类库
|
||
implementation 'androidx.appcompat:appcompat:1.1.0'
|
||
implementation 'androidx.viewpager:viewpager:1.0.0'
|
||
implementation 'androidx.vectordrawable:vectordrawable:1.1.0'
|
||
implementation 'androidx.vectordrawable:vectordrawable-animated:1.1.0'
|
||
implementation 'androidx.fragment:fragment:1.1.0'
|
||
implementation 'com.google.android.material:material:1.4.0'
|
||
|
||
implementation 'cc.winboll.studio:libappbase:2.1.5'
|
||
implementation 'cc.winboll.studio:libapputils:9.4.4'
|
||
implementation 'cc.winboll.studio:libaes:7.6.12'
|
||
}
|