diff --git a/build.gradle.kts b/build.gradle.kts index 1122b61..9ec7f1f 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -109,6 +109,7 @@ tasks { commandLine("git", "tag", "-a", project.version, "-m", "Version ${project.version}") } + val publicationName = "mavenJava" publishing { (publications) { @@ -144,6 +145,16 @@ tasks { } } + val generatePom by creating { + description = "Generates pom.xml for snyk." + group = PublishingPlugin.PUBLISH_TASK_GROUP + dependsOn("generatePomFileForMavenJavaPublication") + val pom = File("build/publications/$publicationName/pom-default.xml") + if (pom.exists()) { + pom.copyTo(File("pom.xml"), true) + } + } + fun findProperty(s: String) = project.findProperty(s) as String? bintray { user = findProperty("bintrayUser") @@ -175,6 +186,6 @@ tasks { } "release" { - dependsOn(gitTag, bintrayUpload) + dependsOn(generatePom, gitTag, bintrayUpload) } } \ No newline at end of file diff --git a/pom.xml b/pom.xml index 155261c..3e11c27 100644 --- a/pom.xml +++ b/pom.xml @@ -1,10 +1,23 @@ - + 4.0.0 net.thauvin.erik pinboard-poster 0.9.3 + + + org.jetbrains.kotlin + kotlin-stdlib + 1.2.50 + compile + + + com.squareup.okhttp3 + okhttp + 3.10.0 + compile + + pinboard-poster Pinboard Poster for Kotlin/Java https://github.com/ethauvin/pinboard-poster @@ -26,22 +39,4 @@ git@github.com:ethauvin/pinboard-poster.git https://github.com/ethauvin/pinboard-poster - - - org.jetbrains.kotlin - kotlin-stdlib - 1.2.10 - - - com.squareup.okhttp3 - okhttp - 3.9.1 - - - org.testng - testng - 6.12 - test - -