整理:build.gradle配置

pull/286/head
pppscn 1 year ago
parent 7bc7bfa514
commit 9f41ff7d0b

@ -71,8 +71,16 @@ android {
buildTypes {
release {
minifyEnabled true
//
debuggable false
jniDebuggable false
//
zipAlignEnabled true
//
shrinkResources true
//
minifyEnabled true
//
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
if (isNeedPackage.toBoolean()) {
signingConfig signingConfigs.release
@ -94,8 +102,16 @@ android {
}
}
debug {
minifyEnabled true
//
debuggable true
jniDebuggable true
//
zipAlignEnabled true
//
shrinkResources true
//
minifyEnabled true
//
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
if (isNeedPackage.toBoolean()) {
signingConfig signingConfigs.release
@ -116,13 +132,6 @@ android {
buildConfigField "String", "APP_ID_UMENG", '"60254fc7425ec25f10f4293e"'
}
}
/*debug {
debuggable true
minifyEnabled false
signingConfig signingConfigs.debug
buildConfigField "String", "APP_ID_UMENG", '"60254fc7425ec25f10f4293e"'
}*/
}
//ABICPU
@ -149,6 +158,7 @@ android {
excludes += ['META-INF/DEPENDENCIES.txt', 'META-INF/LICENSE.txt', 'META-INF/NOTICE.txt', 'META-INF/NOTICE', 'META-INF/LICENSE', 'META-INF/DEPENDENCIES', 'META-INF/notice.txt', 'META-INF/license.txt', 'META-INF/dependencies.txt', 'META-INF/LGPL2.1']
}
}
android.applicationVariants.all { variant ->
// Assigns a different version code for each output APK.
variant.outputs.each {
@ -162,7 +172,6 @@ android {
}
}
sourceSets {
main {
jniLibs.srcDirs = ['libs']
@ -205,7 +214,7 @@ dependencies {
//AutoSizehttps://github.com/JessYanCoding/AndroidAutoSize
implementation 'me.jessyan:autosize:1.2.1'
//umeng
implementation 'com.umeng.umsdk:common:9.5.4'
implementation 'com.umeng.umsdk:common:9.5.6'
implementation 'com.umeng.umsdk:asms:1.6.3'
//
@ -268,6 +277,9 @@ dependencies {
//Location Android LocationManager https://github.com/jenly1314/Location
implementation 'com.github.pppscn:location:1.0.0'
//sockethttps://gitee.com/xuankaicat/kmnkt
//implementation 'com.github.pppscn.kmnkt:socket:2.0.0-alpha06'
}
//X-Library
apply from: 'x-library.gradle'

@ -36,6 +36,23 @@ allprojects {
maven { url 'https://oss.sonatype.org/content/repositories/public' }
maven { url "https://jitpack.io" }
}
//
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
//
tasks.withType(Javadoc) {
options {
encoding 'UTF-8'
charSet 'UTF-8'
links 'http://docs.oracle.com/javase/7/docs/api'
}
}
// build
setBuildDir(new File(rootDir, "build/${path.replaceAll(':', '/')}"))
}
task clean(type: Delete) {

Loading…
Cancel
Save