Skip to content

Commit

Permalink
Add GitHub Actions workflow for Hangar publication
Browse files Browse the repository at this point in the history
Introduce a new GitHub Actions workflow to automate the publishing process to Hangar upon release events. This workflow checks out the repo, sets up JDK 21, and runs Gradle to publish publications to Hangar.
  • Loading branch information
NonSwag committed Aug 31, 2024
1 parent fa2d4f1 commit 2ce6f70
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/hangar-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Hangar Publish

on:
release:
types:
- prereleased
- released

jobs:
build:
env:
HANGAR_API_TOKEN: ${{ secrets.HANGAR_API_TOKEN }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
- name: Publish with Gradle to Hangar
uses: gradle/actions/setup-gradle@v3
with:
arguments: publishAllPublicationsToHangar

0 comments on commit 2ce6f70

Please sign in to comment.