Skip to content

Commit

Permalink
ci: pre-release
Browse files Browse the repository at this point in the history
  • Loading branch information
Apehum committed May 19, 2024
1 parent 138daff commit 30a1940
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 4 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/prerelease-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Publish

on:
push:
branches:
- v1.1

jobs:
build:

runs-on: ubuntu-latest
permissions:
contents: write
packages: write

steps:
- uses: actions/checkout@v3
- name: Set up JDK
uses: actions/setup-java@v3
with:
distribution: temurin
java-version: |
8
16
17
- name: Build with Gradle
uses: gradle/gradle-build-action@v2
with:
arguments: build

- name: Publish to GitHub
uses: Apehum/mc-publish@v1.1
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
github-generate-changelog: true
github-prerelease: true
changelog-file: changelog.md
13 changes: 9 additions & 4 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,11 @@ jobs:
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'
server-id: github # Value of the distributionManagement/repository/id field of the pom.xml
settings-path: ${{ github.workspace }} # location for the settings.xml file
distribution: temurin
java-version: |
8
16
17
- name: Build with Gradle
uses: gradle/gradle-build-action@v2
Expand All @@ -37,6 +38,8 @@ jobs:
files-primary: build/libs/!(*-@(dev|sources|javadoc)).jar
files-secondary: ""

changelog-file: changelog.md

- name: Publish to GitHub
uses: Apehum/mc-publish@v1.1
with:
Expand All @@ -45,3 +48,5 @@ jobs:

files-primary: build/libs/!(*-@(dev|sources|javadoc)).jar
files-secondary: ""

changelog-file: changelog.md

0 comments on commit 30a1940

Please sign in to comment.