Skip to content

Commit

Permalink
Update publish gradle plugin (#754)
Browse files Browse the repository at this point in the history
  • Loading branch information
yinan-symphony committed Apr 3, 2023
1 parent e54e61b commit 494d8ea
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
run: |
mkdir -p ~/.gnupg/
printf "$GPG_KEY_BASE64" | base64 --decode > ~/.gnupg/secring.gpg
./gradlew -PmavenRepoUsername=$MAVEN_USERNAME -PmavenRepoPassword=$MAVEN_PASSWORD -Psigning.keyId=$GPG_KEY_ID -Psigning.secretKeyRingFile=$HOME/.gnupg/secring.gpg -Psigning.password=$GPG_KEY_PASSPHRASE publish closeAndReleaseRepository
./gradlew -PmavenRepoUsername=$MAVEN_USERNAME -PmavenRepoPassword=$MAVEN_PASSWORD -Psigning.keyId=$GPG_KEY_ID -Psigning.secretKeyRingFile=$HOME/.gnupg/secring.gpg -Psigning.password=$GPG_KEY_PASSPHRASE publishToSonatype closeAndReleaseStagingRepository
env:
GPG_KEY_BASE64: ${{ secrets.GPG_KEY_BASE64 }}
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
Expand Down
13 changes: 9 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
plugins {
id "io.codearte.nexus-staging" version "0.22.0"
id "io.github.gradle-nexus.publish-plugin" version "1.3.0"
id "org.owasp.dependencycheck" version "8.2.1"
}

Expand Down Expand Up @@ -40,10 +40,15 @@ allprojects {
defaultTasks 'build'
}

nexusStaging {
username = rootProject.ext.mavenRepoUsername
password = rootProject.ext.mavenRepoPassword
nexusPublishing {
packageGroup = 'org.finos'

repositories {
sonatype {
username = project.ext.mavenRepoUsername
password = project.ext.mavenRepoPassword
}
}
}

repositories {
Expand Down

0 comments on commit 494d8ea

Please sign in to comment.