File tree Expand file tree Collapse file tree 1 file changed +8
-7
lines changed Expand file tree Collapse file tree 1 file changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ plugins {
2
2
id ' java-library'
3
3
id ' idea'
4
4
id ' maven-publish'
5
- id " de.marcphilipp.nexus-publish" version " 0.4.0"
6
5
id ' signing'
7
6
id ' com.github.sherter.google-java-format' version ' 0.8'
8
7
id ' io.codearte.nexus-staging' version ' 0.12.0'
@@ -203,19 +202,21 @@ publishing {
203
202
}
204
203
}
205
204
}
206
- }
207
205
208
- nexusPublishing {
209
206
repositories {
210
207
maven {
211
- nexusUrl = uri(" https://oss.sonatype.org/service/local/staging/deploy/maven2/" )
212
- snapshotRepositoryUrl = uri(" https://oss.sonatype.org/content/repositories/snapshots/" )
213
- username = System . getenv(' SONATYPE_USERNAME' )
214
- password = System . getenv(' SONATYPE_PASSWORD' )
208
+ def releasesRepoUrl = " https://oss.sonatype.org/service/local/staging/deploy/maven2/"
209
+ def snapshotsRepoUrl = " https://oss.sonatype.org/content/repositories/snapshots/"
210
+ url = version. endsWith(' SNAPSHOT' ) ? snapshotsRepoUrl : releasesRepoUrl
211
+ credentials {
212
+ username System . getenv(' SONATYPE_USERNAME' )
213
+ password System . getenv(' SONATYPE_PASSWORD' )
214
+ }
215
215
}
216
216
}
217
217
}
218
218
219
+
219
220
signing {
220
221
sign publishing. publications. mavenJava
221
222
sign configurations. archives
You can’t perform that action at this time.
0 commit comments