@@ -7,7 +7,7 @@ buildscript { // Configuration for building
7
7
plugins {
8
8
id ' java-library'
9
9
id ' maven-publish'
10
- id ' signing '
10
+ id " com.vanniktech.maven.publish " version " 0.34.0 "
11
11
}
12
12
13
13
apply plugin : ' java' // standard Java tasks
@@ -29,53 +29,38 @@ repositories { // repositories for Jar's you access in your code
29
29
mavenCentral()
30
30
}
31
31
32
- publishing {
33
- publications {
34
- authLib(MavenPublication ) {
35
- pom {
36
- name = ' Fleet Engine Auth Library'
37
- description = ' Provides a set of tools to simplify the Fleet Engine setup process.'
38
- url = ' https://github.com/googlemaps/java-fleetengine-auth'
39
- licenses {
40
- license {
41
- name = ' The Apache License, Version 2.0'
42
- url = ' http://www.apache.org/licenses/LICENSE-2.0.txt'
43
- }
44
- }
45
- organization {
46
- name = ' Google, Inc.'
47
- url = ' http://www.google.com'
48
- }
49
- issueManagement {
50
- system = ' GitHub Issues'
51
- url = ' http://github.com/googlemaps/java-fleetengine-auth/issues'
52
- }
53
- scm {
54
- connection = ' scm:git:git://github.com/googlemaps/java-fleetengine-auth.git'
55
- developerConnection = ' scm:git:ssh://github.com/googlemaps/java-fleetengine-auth.git'
56
- url = ' http://github.com/googlemaps/java-fleetengine-auth/'
57
- tag = ' HEAD'
58
- }
59
- developers {
60
- developer {
61
- id = ' danielfbright'
62
- name = ' Daniel Bright'
63
- }
64
- }
32
+ mavenPublishing {
33
+ publishToMavenCentral()
34
+ signAllPublications()
35
+ pom {
36
+ name = " Fleet Engine Auth Library"
37
+ description = " Provides a set of tools to simplify the Fleet Engine setup process."
38
+ url = " https://github.com/googlemaps/java-fleetengine-auth"
39
+ licenses {
40
+ license {
41
+ name = " The Apache License, Version 2.0"
42
+ url = " http://www.apache.org/licenses/LICENSE-2.0.txt"
43
+ distribution = " http://www.apache.org/licenses/LICENSE-2.0.txt"
65
44
}
66
- groupId group
67
- artifactId project. ext. artifactId
68
- version version
69
- from components. java
70
45
}
71
- }
72
- repositories {
73
- maven {
74
- name = " mavencentral"
75
- url = " https://oss.sonatype.org/service/local/staging/deploy/maven2/"
76
- credentials {
77
- username sonatypeUsername
78
- password sonatypePassword
46
+ organization {
47
+ name = ' Google, Inc.'
48
+ url = ' http://www.google.com'
49
+ }
50
+ issueManagement {
51
+ system = ' GitHub Issues'
52
+ url = ' http://github.com/googlemaps/java-fleetengine-auth/issues'
53
+ }
54
+ scm {
55
+ connection = ' scm:git:git://github.com/googlemaps/java-fleetengine-auth.git'
56
+ developerConnection = ' scm:git:ssh://github.com/googlemaps/java-fleetengine-auth.git'
57
+ url = ' http://github.com/googlemaps/java-fleetengine-auth/'
58
+ tag = ' HEAD'
59
+ }
60
+ developers {
61
+ developer {
62
+ id. set(" google" )
63
+ name. set(" Google Inc." )
79
64
}
80
65
}
81
66
}
@@ -100,32 +85,3 @@ dependencies {
100
85
testImplementation ' com.google.truth:truth:1.1'
101
86
testImplementation ' org.mockito:mockito-core:3.12.4'
102
87
}
103
-
104
- signing {
105
- sign publishing. publications. authLib
106
- }
107
-
108
- task javadocJar (type : Jar , dependsOn : javadoc) {
109
- archiveClassifier = ' javadoc'
110
- from ' build/docs/javadoc'
111
- }
112
-
113
- task sourcesJar (type : Jar ) {
114
- from sourceSets. main. allSource
115
- archiveClassifier = ' sources'
116
- }
117
-
118
- artifacts {
119
- archives jar
120
- archives javadocJar
121
- archives sourcesJar
122
- }
123
-
124
- java {
125
- withJavadocJar()
126
- withSourcesJar()
127
- }
128
-
129
-
130
- compileJava. options. encoding = ' UTF-8'
131
- javadoc. options. encoding = ' UTF-8'
0 commit comments