@@ -7,12 +7,12 @@ import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
77plugins {
88 java
99 signing
10- kotlin(" jvm" ) version " 1.5.32 "
11- id(" com.adarshr.test-logger" ) version " 2.1.1 "
12- id(" io.codearte.nexus-staging" ) version " 0.22 .0"
10+ kotlin(" jvm" ) version " 1.7.21 "
11+ id(" com.adarshr.test-logger" ) version " 3.2.0 "
12+ id(" io.codearte.nexus-staging" ) version " 0.30 .0"
1313 id(" nebula.release" ) version " 17.1.0"
1414 id(" maven-publish" )
15- id(" io.gitlab.arturbosch.detekt" ) version " 1.17.1 "
15+ id(" io.gitlab.arturbosch.detekt" ) version " 1.22.0 "
1616 id(" org.gradle.test-retry" ) version " 1.4.1"
1717}
1818
@@ -24,14 +24,14 @@ dependencies {
2424 implementation(kotlin(" stdlib-jdk8" ))
2525 implementation(kotlin(" reflect" ))
2626
27- api(" com.google.code.gson:gson:2.8.6 " )
27+ api(" com.google.code.gson:gson:2.10 " )
2828 api(" org.apache.httpcomponents:httpclient:4.5.13" )
2929
30- testImplementation(" org.junit.jupiter:junit-jupiter:5.7.0 " )
31- testImplementation(" org.reflections:reflections:0.9.11 " )
32- testImplementation(" uk.co.jemos.podam:podam:7.2.6 .RELEASE" )
30+ testImplementation(" org.junit.jupiter:junit-jupiter:5.9.1 " )
31+ testImplementation(" org.reflections:reflections:0.10.2 " )
32+ testImplementation(" uk.co.jemos.podam:podam:7.2.11 .RELEASE" )
3333
34- detektPlugins(" io.gitlab.arturbosch.detekt:detekt-formatting:1.17.1 " )
34+ detektPlugins(" io.gitlab.arturbosch.detekt:detekt-formatting:1.22.0 " )
3535}
3636
3737configure<JavaPluginConvention > {
@@ -87,6 +87,7 @@ tasks.withType<Sign> {
8787 doFirst {
8888 settingsProvider.validateGPGSecrets()
8989 }
90+ dependsOn(tasks.getByName(" build" ))
9091}
9192
9293tasks.withType<PublishToMavenRepository > {
@@ -95,24 +96,26 @@ tasks.withType<PublishToMavenRepository> {
9596 }
9697}
9798
98- tasks.register(" printFinalReleaseNode " ) {
99+ tasks.register(Tasks . PRINT_FINAL_RELEASE_NOTE_TASK_NAME ) {
99100 doLast {
100- printFinalReleaseNode (
101+ printFinalReleaseNote (
101102 groupId = PublicationSettings .GROUP_ID ,
102103 artifactId = PublicationSettings .ARTIFACT_ID ,
103104 sanitizedVersion = project.sanitizeVersion()
104105 )
105106 }
107+ dependsOn(tasks.getByName(" final" ))
106108}
107109
108- tasks.register(" printDevSnapshotReleaseNode " ) {
110+ tasks.register(Tasks . PRINT_DEV_SNAPSHOT_RELEASE_NOTE_TASK_NAME ) {
109111 doLast {
110- printDevSnapshotReleaseNode (
112+ printDevSnapshotReleaseNote (
111113 groupId = PublicationSettings .GROUP_ID ,
112114 artifactId = PublicationSettings .ARTIFACT_ID ,
113115 sanitizedVersion = project.sanitizeVersion()
114116 )
115117 }
118+ dependsOn(tasks.getByName(" devSnapshot" ))
116119}
117120
118121detekt {
@@ -227,7 +230,7 @@ fun Project.sanitizeVersion(): String {
227230
228231fun Project.isSnapshotVersion () = version.toString().contains(" -dev." )
229232
230- fun printFinalReleaseNode (groupId : String , artifactId : String , sanitizedVersion : String ) {
233+ fun printFinalReleaseNote (groupId : String , artifactId : String , sanitizedVersion : String ) {
231234 println ()
232235 println (" ========================================================" )
233236 println ()
@@ -249,7 +252,7 @@ fun printFinalReleaseNode(groupId: String, artifactId: String, sanitizedVersion:
249252 println ()
250253}
251254
252- fun printDevSnapshotReleaseNode (groupId : String , artifactId : String , sanitizedVersion : String ) {
255+ fun printDevSnapshotReleaseNote (groupId : String , artifactId : String , sanitizedVersion : String ) {
253256 println ()
254257 println (" ========================================================" )
255258 println ()
@@ -330,3 +333,8 @@ object Consts {
330333 const val SLOW_TESTS_LOGGING_THRESHOLD_MS = 30_000L
331334 const val MAX_TEST_RETRIES_COUNT = 3
332335}
336+
337+ object Tasks {
338+ const val PRINT_FINAL_RELEASE_NOTE_TASK_NAME = " printFinalReleaseNote"
339+ const val PRINT_DEV_SNAPSHOT_RELEASE_NOTE_TASK_NAME = " printDevSnapshotReleaseNote"
340+ }
0 commit comments