1
- /**
2
- * <pre >
3
- * author: blankj
4
- * blog : http://blankj.com
5
- * time : 2019/07/13
6
- * desc :
7
- * </pre>
8
- */
9
1
class Config {
10
2
11
3
static applicationId = ' com.blankj.androidutilcode'
@@ -14,74 +6,84 @@ class Config {
14
6
static compileSdkVersion = 29
15
7
static minSdkVersion = 14
16
8
static targetSdkVersion = 29
17
- static versionCode = 1_030_006
18
- static versionName = ' 1.30.7-alpha1 ' // E.g. 1.9.72 => 1,009,072
9
+ static versionCode = 1_030_007
10
+ static versionName = ' 1.31.0 ' // E.g. 1.9.72 => 1,009,072
19
11
20
12
// lib version
21
13
static gradlePluginVersion = ' 4.1.0'
22
14
static kotlinVersion = ' 1.3.72'
23
15
static androidxVersion = ' 1.0.0'
24
16
25
- static depConfig = [
26
- /* Never delete this line*/
27
- /* Generated by "config.json"*/
28
- plugin_api_gradle_plugin : new DepConfig (true , true , " :plugin:api-gradle-plugin" ),
29
- plugin_bus_gradle_plugin : new DepConfig (true , true , " :plugin:bus-gradle-plugin" ),
30
- plugin_lib_base_transform : new DepConfig (true , false , " :plugin:lib:base-transform" , " com.blankj:base-transform:1.0" ),
31
- feature_mock : new DepConfig (false , true , " :feature:mock" ),
32
- feature_launcher_app : new DepConfig (true , true , " :feature:launcher:app" ),
33
- feature_main_app : new DepConfig (false , true , " :feature:main:app" ),
34
- feature_main_pkg : new DepConfig (true , true , " :feature:main:pkg" ),
35
- feature_subutil_app : new DepConfig (false , true , " :feature:subutil:app" ),
36
- feature_subutil_pkg : new DepConfig (true , true , " :feature:subutil:pkg" ),
37
- feature_subutil_export : new DepConfig (true , true , " :feature:subutil:export" ),
38
- feature_utilcode_app : new DepConfig (false , true , " :feature:utilcode:app" ),
39
- feature_utilcode_pkg : new DepConfig (true , true , " :feature:utilcode:pkg" ),
40
- feature_utilcode_export : new DepConfig (true , true , " :feature:utilcode:export" , " com.blankj:utilcode-export:1.1" ),
41
- lib_base : new DepConfig (true , true , " :lib:base" ),
42
- lib_common : new DepConfig (true , true , " :lib:common" ),
43
- lib_subutil : new DepConfig (true , true , " :lib:subutil" ),
44
- lib_utilcode : new DepConfig (true , true , " :lib:utilcode" , " com.blankj:utilcodex:$versionName " ),
45
- lib_utildebug : new DepConfig (true , true , " :lib:utildebug" ),
46
- lib_utildebug_no_op : new DepConfig (true , true , " :lib:utildebug-no-op" ),
47
- /* Never delete this line*/
48
- plugin_gradle : new DepConfig (pluginPath : " com.android.tools.build:gradle:$gradlePluginVersion " ),
49
- plugin_kotlin : new DepConfig (pluginPath : " org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion " ),
50
- plugin_traute : new DepConfig (pluginPath : " tech.harmonysoft:traute-gradle:1.1.10" , pluginId : " tech.harmonysoft.oss.traute" ),// 注解转非空判断
17
+ static modules = [
18
+ /* Don't delete this line*/
19
+ /* Generated by "module_config.json"*/
20
+ plugin_api_gradle_plugin : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./plugin/api-gradle-plugin" ),
21
+ plugin_bus_gradle_plugin : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./plugin/bus-gradle-plugin" ),
22
+ plugin_lib_base_transform : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./plugin/lib/base-transform" , remotePath : " com.blankj:base-transform:1.0" ),
23
+ plugin_buildSrc_plugin : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./plugin/buildSrc-plugin" ),
24
+ feature_mock : new ModuleConfig (isApply : false , useLocal : true , localPath : " ./feature/mock" ),
25
+ feature_launcher_app : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./feature/launcher/app" ),
26
+ feature_main_app : new ModuleConfig (isApply : false , useLocal : true , localPath : " ./feature/main/app" ),
27
+ feature_main_pkg : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./feature/main/pkg" ),
28
+ feature_subutil_app : new ModuleConfig (isApply : false , useLocal : true , localPath : " ./feature/subutil/app" ),
29
+ feature_subutil_pkg : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./feature/subutil/pkg" ),
30
+ feature_subutil_export : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./feature/subutil/export" ),
31
+ feature_utilcode_app : new ModuleConfig (isApply : false , useLocal : true , localPath : " ./feature/utilcode/app" ),
32
+ feature_utilcode_pkg : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./feature/utilcode/pkg" ),
33
+ feature_utilcode_export : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./feature/utilcode/export" , remotePath : " com.blankj:utilcode-export:1.1" ),
34
+ lib_base : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./lib/base" ),
35
+ lib_common : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./lib/common" ),
36
+ lib_subutil : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./lib/subutil" ),
37
+ lib_utilcode : new ModuleConfig (isApply : true , useLocal : false , localPath : " ./lib/utilcode" , remotePath : " com.blankj:utilcode:$Config . versionName " ),
38
+ lib_utildebug : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./lib/utildebug" ),
39
+ lib_utildebug_no_op : new ModuleConfig (isApply : true , useLocal : true , localPath : " ./lib/utildebug-no-op" ),
40
+ /* Don't delete this line*/
41
+ ]
42
+
43
+ static plugins = [
44
+ plugin_gradle : new PluginConfig (path : " com.android.tools.build:gradle:$gradlePluginVersion " ),
45
+ plugin_kotlin : new PluginConfig (path : " org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion " ),
46
+ // 上传到 maven
47
+ plugin_maven : new PluginConfig (path : " com.github.dcendents:android-maven-gradle-plugin:2.1" , id : " com.github.dcendents.android-maven" ),
51
48
52
- // 上传新版本插件更新 pluginPath 中的版本号,并设置 isApply = false
49
+ // 上传新版本插件更新 path 中的版本号,并设置 isApply = false
53
50
// 通过 mavenLocal 上传本地版本,设置 isApply = true 即可应用插件来调试,最后通过 bintrayUpload 来发布插件
54
- plugin_api : new DepConfig (isApply : true , useLocal : false , pluginPath : " com.blankj:api-gradle-plugin:1.5" , pluginId : " com.blankj.api" ),
51
+ plugin_api : new PluginConfig (isApply : true , useLocal : false , path : " com.blankj:api-gradle-plugin:1.5" , id : " com.blankj.api" ),
55
52
// ./gradlew clean :plugin_api-gradle-plugin:mavenLocal // 上传到本地 mavenLocal
56
53
// ./gradlew clean :plugin_api-gradle-plugin:bintrayUpload // 上传到 jcenter
57
- plugin_bus : new DepConfig (isApply : true , useLocal : false , pluginPath : " com.blankj:bus-gradle-plugin:2.6" , pluginId : " com.blankj.bus" ),
54
+ plugin_bus : new PluginConfig (isApply : true , useLocal : false , path : " com.blankj:bus-gradle-plugin:2.6" , id : " com.blankj.bus" ),
58
55
// ./gradlew clean :plugin_bus-gradle-plugin:mavenLocal // 上传到本地 mavenLocal
59
56
// ./gradlew clean :plugin_bus-gradle-plugin:bintrayUpload // 上传到 jcenter
57
+ plugin_buildSrc : new PluginConfig (isApply : true , useLocal : false , path : " com.blankj:buildSrc-plugin:1.0" , id : " com.blankj.buildSrc" ),
58
+ // ./gradlew clean :plugin_bus-gradle-plugin:mavenLocal // 上传到本地 mavenLocal
59
+ // ./gradlew clean :plugin_bus-gradle-plugin:bintrayUpload // 上传到 jcenter
60
+ ]
60
61
61
- androidx_appcompat : new DepConfig (" androidx.appcompat:appcompat:$androidxVersion " ),
62
- androidx_material : new DepConfig (" com.google.android.material:material:$androidxVersion " ),
63
- androidx_multidex : new DepConfig (" androidx.multidex:multidex:2.0.0" ),
64
- androidx_constraint : new DepConfig (" androidx.constraintlayout:constraintlayout:1.1.3" ),
62
+ static libs = [
63
+ androidx_appcompat : new LibConfig (path : " androidx.appcompat:appcompat:$androidxVersion " ),
64
+ androidx_material : new LibConfig (path : " com.google.android.material:material:$androidxVersion " ),
65
+ androidx_multidex : new LibConfig (path : " androidx.multidex:multidex:2.0.0" ),
66
+ androidx_constraint : new LibConfig (path : " androidx.constraintlayout:constraintlayout:1.1.3" ),
65
67
66
- kotlin : new DepConfig ( " org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlinVersion " ),
68
+ kotlin : new LibConfig ( path : " org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlinVersion " ),
67
69
68
- leakcanary : new DepConfig ( " com.squareup.leakcanary:leakcanary-android:2.1" ),
70
+ leakcanary : new LibConfig ( path : " com.squareup.leakcanary:leakcanary-android:2.1" ),
69
71
70
- free_proguard : new DepConfig ( " com.blankj:free-proguard:1.0.2" ),
71
- swipe_panel : new DepConfig ( " com.blankj:swipe-panel:1.2" ),
72
+ free_proguard : new LibConfig ( path : " com.blankj:free-proguard:1.0.2" ),
73
+ swipe_panel : new LibConfig ( path : " com.blankj:swipe-panel:1.2" ),
72
74
73
- gson : new DepConfig ( " com.google.code.gson:gson:2.8.5" ),
74
- glide : new DepConfig ( " com.github.bumptech.glide:glide:4.7.1" ),
75
- retrofit : new DepConfig ( " com.squareup.retrofit2:retrofit:2.4.0" ),
76
- commons_io : new DepConfig ( " commons-io:commons-io:2.6" ),
75
+ gson : new LibConfig ( path : " com.google.code.gson:gson:2.8.5" ),
76
+ glide : new LibConfig ( path : " com.github.bumptech.glide:glide:4.7.1" ),
77
+ retrofit : new LibConfig ( path : " com.squareup.retrofit2:retrofit:2.4.0" ),
78
+ commons_io : new LibConfig ( path : " commons-io:commons-io:2.6" ),
77
79
78
- eventbus_lib : new DepConfig ( " org.greenrobot:eventbus:3.1.1" ),
79
- eventbus_processor : new DepConfig ( " org.greenrobot:eventbus-annotation-processor:3.0.1" ),
80
+ eventbus_lib : new LibConfig ( path : " org.greenrobot:eventbus:3.1.1" ),
81
+ eventbus_processor : new LibConfig ( path : " org.greenrobot:eventbus-annotation-processor:3.0.1" ),
80
82
81
- photo_view : new DepConfig ( " com.github.chrisbanes:PhotoView:2.0.0" ),
83
+ photo_view : new LibConfig ( path : " com.github.chrisbanes:PhotoView:2.0.0" ),
82
84
83
- test_junit : new DepConfig ( " junit:junit:4.12" ),
84
- test_robolectric : new DepConfig ( " org.robolectric:robolectric:4.3.1" ),
85
+ test_junit : new LibConfig ( path : " junit:junit:4.12" ),
86
+ test_robolectric : new LibConfig ( path : " org.robolectric:robolectric:4.3.1" ),
85
87
]
86
88
}
87
89
// ./gradlew clean :lib_utilcode:bintrayUpload
0 commit comments