的
This commit is contained in:
@@ -0,0 +1,46 @@
|
||||
apply plugin: 'com.android.library'
|
||||
|
||||
android {
|
||||
compileSdkVersion 27
|
||||
|
||||
defaultConfig {
|
||||
minSdkVersion 19
|
||||
targetSdkVersion 27
|
||||
versionCode 13
|
||||
versionName "1.1.3"
|
||||
}
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
|
||||
}
|
||||
}
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation fileTree(dir: 'libs', include: ['*.jar'])
|
||||
}
|
||||
|
||||
tasks.withType(Javadoc) {
|
||||
options.addStringOption('Xdoclint:none', '-quiet')
|
||||
options.addStringOption('encoding', 'UTF-8')
|
||||
}
|
||||
|
||||
def libVersion = '1.2.0'
|
||||
task makeJar(type: Jar) {
|
||||
// 指定生成的jar名
|
||||
def rootDir = project.getRootDir();
|
||||
def parentDir = project.getRootDir().getParentFile().getAbsolutePath();
|
||||
|
||||
delete 'build/libs/*.*'
|
||||
archiveName 'android-common-' + libVersion + '.jar'
|
||||
destinationDir = file('build/libs')
|
||||
// 从哪里打包class文件
|
||||
from('build/intermediates/classes/release/')
|
||||
// 打包到jar后的目录结构
|
||||
// 去掉不需要打包的目录和文件
|
||||
exclude('test/', 'BuildConfig.class', 'R.class', 'R\$*.class', 'META-INF/')
|
||||
}
|
||||
Reference in New Issue
Block a user