Skip to content

Commit

Permalink
Added Nexus config to build
Browse files Browse the repository at this point in the history
  • Loading branch information
tomakehurst committed Nov 9, 2023
1 parent 9f67bae commit 355562f
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -215,3 +215,17 @@ protobuf {

processTestResources.dependsOn generateProto
processTestResources.dependsOn generateTestProto

nexusPublishing {
// See https://github.com/wiremock/community/blob/main/infra/maven-central.md
repositories {
sonatype {
def envUsername = providers.environmentVariable("OSSRH_USERNAME").orElse("").get()
def envPassword = providers.environmentVariable("OSSRH_TOKEN").orElse("").get()
if (!envUsername.isEmpty() && !envPassword.isEmpty()) {
username.set(envUsername)
password.set(envPassword)
}
}
}
}

0 comments on commit 355562f

Please sign in to comment.