File tree Expand file tree Collapse file tree 6 files changed +78
-14
lines changed Expand file tree Collapse file tree 6 files changed +78
-14
lines changed Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ buildscript {
6
6
}
7
7
dependencies {
8
8
// 加载自定义插件
9
- classpath ' com.winwang.plugin.lifecycle:ApplicationInit:1 .0'
9
+ classpath ' com.winwang.plugin.lifecycle:applifecycle-plugin:1.0 .0'
10
10
}
11
11
}
12
12
Original file line number Diff line number Diff line change 7
7
sourceCompatibility = JavaVersion . VERSION_1_8
8
8
targetCompatibility = JavaVersion . VERSION_1_8
9
9
}
10
+
11
+ /**
12
+ * 发布jitpack
13
+ */
14
+ afterEvaluate {
15
+ publishing {
16
+ publications {
17
+ release(MavenPublication ) {
18
+ from components. java
19
+ groupId = project. groupId
20
+ artifactId = ' applifecycle-annotation'
21
+ version = " 1.0.0"
22
+ }
23
+ }
24
+ }
25
+ }
Original file line number Diff line number Diff line change @@ -38,4 +38,20 @@ dependencies {
38
38
androidTestImplementation ' androidx.test.ext:junit:1.1.3'
39
39
androidTestImplementation ' androidx.test.espresso:espresso-core:3.4.0'
40
40
api project(path : ' :applifecycle-annotation' )
41
+ }
42
+
43
+ /**
44
+ * 发布jitpack
45
+ */
46
+ afterEvaluate {
47
+ publishing {
48
+ publications {
49
+ release(MavenPublication ) {
50
+ from components. release
51
+ groupId = project. groupId
52
+ artifactId = ' applifecycle-api'
53
+ version = project. libVersion
54
+ }
55
+ }
56
+ }
41
57
}
Original file line number Diff line number Diff line change @@ -30,24 +30,39 @@ dependencies {
30
30
31
31
// from components.java 发布java library
32
32
// from components.release 发布Android Library
33
+ // afterEvaluate {
34
+ // publishing {
35
+ // //发布服务器类似jitpack
36
+ // publications {
37
+ // release(MavenPublication) {
38
+ // from components.java
39
+ // groupId = 'com.winwang.plugin.lifecycle'
40
+ // artifactId = 'ApplicationInit'
41
+ // version = 1.0
42
+ // }
43
+ // }
44
+ // //发布仓库repository
45
+ // repositories {
46
+ // maven {
47
+ // url = "file:///Users/winwang/.m2/repository/"
48
+ // }
49
+ //
50
+ // }
51
+ // }
52
+ // }
53
+
54
+ /**
55
+ * 发布jitpack
56
+ */
33
57
afterEvaluate {
34
58
publishing {
35
- // 发布服务器类似jitpack
36
59
publications {
37
60
release(MavenPublication ) {
38
61
from components. java
39
- groupId = ' com.winwang.plugin.lifecycle '
40
- artifactId = ' ApplicationInit '
41
- version = 1.0
62
+ groupId = project . groupId
63
+ artifactId = ' applifecycle-plugin '
64
+ version = project . libVersion
42
65
}
43
66
}
44
- // 发布仓库repository
45
- repositories {
46
- maven {
47
- url = " file:///Users/winwang/.m2/repository/"
48
- }
49
-
50
- }
51
-
52
67
}
53
68
}
Original file line number Diff line number Diff line change @@ -17,5 +17,20 @@ dependencies {
17
17
implementation ' com.squareup:javapoet:1.13.0'
18
18
implementation project(path : ' :applifecycle-annotation' )
19
19
// 依赖apt-annotation
20
+ }
20
21
22
+ /**
23
+ * 发布jitpack
24
+ */
25
+ afterEvaluate {
26
+ publishing {
27
+ publications {
28
+ release(MavenPublication ) {
29
+ from components. java
30
+ groupId = project. groupId
31
+ artifactId = ' applifecycle-processor'
32
+ version = project. libVersion
33
+ }
34
+ }
35
+ }
21
36
}
Original file line number Diff line number Diff line change @@ -21,4 +21,6 @@ kotlin.code.style=official
21
21
# resources declared in the library itself and none from the library's dependencies,
22
22
# thereby reducing the size of the R class for that library
23
23
android.nonTransitiveRClass =true
24
- # android.suppressUnsupportedCompileSdk=32
24
+ # android.suppressUnsupportedCompileSdk=32
25
+ groupId =com.github.WinWang
26
+ libVersion =1.0.0
You can’t perform that action at this time.
0 commit comments