Skip to content

Commit

Permalink
Fix signing task in build.gradle (#1325)
Browse files Browse the repository at this point in the history
* Fix the signing task configuration in build.gradle so that releases are signed.
  • Loading branch information
lbergelson authored Mar 18, 2019
1 parent 2b5f3bc commit 5dcfd73
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -159,14 +159,6 @@ task sourcesJar(type: Jar) {
archiveClassifier.set('sources')
}

/**
* Sign non-snapshot releases with our secret key. This should never need to be invoked directly.
*/
signing {
required { isRelease && gradle.taskGraph.hasTask("publishHtsjdkPublicationToMavenRepository") }
sign configurations.archives
}

publishing {
publications {
htsjdk(MavenPublication) {
Expand Down Expand Up @@ -217,4 +209,15 @@ publishing {
}
}

/**
* Sign non-snapshot releases with our secret key. This should never need to be invoked directly.
*/
signing {
required { isRelease && gradle.taskGraph.hasTask("publishHtsjdkPublicationToMavenRepository") }
sign publishing.publications.htsjdk
}
gradle.taskGraph.beforeTask { Task task ->
println "executing $task ..."
}

task install(dependsOn:publishToMavenLocal)

0 comments on commit 5dcfd73

Please sign in to comment.