Build Rush v3.0.2 #6
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Automatically builds and publishes the mod when a new release is created on GitHub. | |
# It uploads the mod to GitHub, CurseForge and Modrinth. | |
name: Release | |
on: | |
release: | |
types: [published] | |
jobs: | |
publish: | |
name: Build & Publish | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v1 | |
with: | |
java-version: '17' | |
- name: Grant execute permission for gradlew | |
run: chmod +x ./gradlew | |
- name: Build with Gradle | |
run: ./gradlew clean build -Pversion=${{ github.event.release.tag_name }} | |
- name: Publish mod to GitHub, CurseForge and Modrinth | |
id: publish | |
uses: Kir-Antipov/mc-publish@v3.3 | |
with: | |
curseforge-token: ${{ secrets.CURSEFORGE_TOKEN }} | |
modrinth-token: ${{ secrets.MODRINTH_TOKEN }} | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
changelog: ${{ github.event.release.body }} | |
java: 17 | |
modrinth-featured: false | |
- name: Add job summary | |
run: | | |
echo "# Results" >> $GITHUB_STEP_SUMMARY | |
echo "- [CurseForge Link](${{ steps.publish.outputs.curseforge-url }})" >> $GITHUB_STEP_SUMMARY | |
echo "- [Modrinth Link](${{ steps.publish.outputs.modrinth-url }})" >> $GITHUB_STEP_SUMMARY | |
echo "- [GitHub Link](${{ steps.publish.outputs.github-url }})" >> $GITHUB_STEP_SUMMARY | |
echo "# Changelog" >> $GITHUB_STEP_SUMMARY | |
echo "${{ github.event.release.body }}" >> $GITHUB_STEP_SUMMARY |