Skip to content

Commit c7c1a51

Browse files
committed
个性化 aar 输出文件名配置
1 parent 0ede651 commit c7c1a51

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

library/build.gradle

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,13 @@ android {
1515
// 剔除这个包下的所有文件(不会移除签名信息)
1616
exclude 'META-INF/*******'
1717
}
18+
19+
android.libraryVariants.configureEach { variant ->
20+
// aar 输出文件名配置
21+
variant.outputs.configureEach { output ->
22+
outputFileName = "${rootProject.name}-${android.defaultConfig.versionName}.aar"
23+
}
24+
}
1825
}
1926

2027
dependencies {

0 commit comments

Comments
 (0)