Skip to content

Commit

Permalink
Merge pull request #3 from Funkatronics/release-versioning
Browse files Browse the repository at this point in the history
CI Versioning
  • Loading branch information
Funkatronics authored Sep 20, 2023
2 parents 7dcf02e + bffb5d6 commit 6efbba8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ jobs:
publish:
runs-on: macos-latest
needs: build
if: ${{ github.event_name == 'release' }}
if: ${{ github.event_name == 'release' && startsWith(github.event.release.tag_name, 'v') }}

steps:
- name: Checkout
Expand All @@ -58,10 +58,11 @@ jobs:
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Publish to Maven Central
run: ./gradlew clean publishAllPublicationsToMavenCentral --stacktrace
run: ./gradlew clean publishAllPublicationsToMavenCentral --stacktrace -P version=${TAG:1}
env:
ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.SONATYPE_NEXUS_USERNAME }}
ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.SONATYPE_NEXUS_PASSWORD }}
ORG_GRADLE_PROJECT_signingInMemoryKey: ${{ secrets.ARTIFACT_SIGNING_PRIVATE_KEY }}
ORG_GRADLE_PROJECT_signingInMemoryKeyId: ${{ secrets.ARTIFACT_SIGNING_PRIVATE_KEY_ID }}
ORG_GRADLE_PROJECT_signingInMemoryKeyPassword: ${{ secrets.ARTIFACT_SIGNING_PRIVATE_KEY_PASSWORD }}
TAG: ${{ github.event.release.tag_name }}

0 comments on commit 6efbba8

Please sign in to comment.