Skip to content

Commit

Permalink
Support publishing to Maven
Browse files Browse the repository at this point in the history
  • Loading branch information
GregDThomas committed Nov 3, 2024
1 parent 7cc4a28 commit 5d3980f
Show file tree
Hide file tree
Showing 4 changed files with 315 additions and 261 deletions.
28 changes: 26 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,22 +8,46 @@ jobs:

steps:
- uses: actions/checkout@v4

- name: Set up JDK 1.8
uses: actions/setup-java@v4
with:
java-version: 8.0
distribution: temurin
cache: 'gradle'

- name: Build with Gradle
run: ./gradlew build
run: ./gradlew clean build

- name: Archive artifacts
uses: actions/upload-artifact@v4
with:
name: artifacts
path: build/libs

- name: Archive code reports
uses: actions/upload-artifact@v4
if: always()
with:
name: code-reports
path: build/reports
path: build/reports

publish:
runs-on: ubuntu-latest
needs: build
if: ${{ contains(github.repository, 'igniterealtime/') && ( ( github.event_name == 'push' && github.ref == 'refs/heads/main' ) || contains(github.ref, 'refs/tags/') ) }}
steps:
- uses: actions/checkout@v4

- name: Set up JDK 1.8
uses: actions/setup-java@v4
with:
java-version: 8.0
distribution: temurin
cache: 'gradle'

- name: Publish
run: ./gradlew publish
env:
IGNITE_REALTIME_MAVEN_USERNAME: ${{ secrets.IGNITE_REALTIME_MAVEN_USERNAME }}
IGNITE_REALTIME_MAVEN_PASSWORD: ${{ secrets.IGNITE_REALTIME_MAVEN_PASSWORD }}
Loading

0 comments on commit 5d3980f

Please sign in to comment.