Skip to content

Make the "fabricloader" dependency in fabric.mod.json get its version… #45

Make the "fabricloader" dependency in fabric.mod.json get its version…

Make the "fabricloader" dependency in fabric.mod.json get its version… #45

Workflow file for this run

# Automatically build the project and run any configured tests for every push
# and submitted pull request. This can help catch issues that only occur on
# certain platforms or Java versions, and provides a first line of defence
# against bad commits.
name: main
on:
push:
pull_request:
workflow_dispatch:
inputs:
shouldPublish:
description: 'Should the mod be published'
required: true
type: boolean
jobs:
main:
permissions:
contents: write
environment: mc-publish
runs-on: ubuntu-latest
steps:
- name: checkout repository
uses: actions/checkout@v4
- name: validate gradle wrapper
uses: gradle/actions/wrapper-validation@v4
- name: setup jdk
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'microsoft'
- name: make gradle wrapper executable
run: chmod +x ./gradlew
- name: build
run: ./gradlew build
- name: capture build artifacts
uses: actions/upload-artifact@v4
with:
name: Artifacts
path: build/libs/
- name: Publish
id: publish
uses: Kira-NT/mc-publish@v3.3.0
if: "
(github.event_name == 'workflow_dispatch' && github.event.inputs.shouldPublish) ||
(github.event_name == 'push' && contains(github.event.head_commit.message, '[publish]'))"
with:
changelog-file: CHANGELOG.md
modrinth-id: hxSZAaAL
modrinth-token: ${{ secrets.MODRINTH_TOKEN }}
curseforge-id: 1302854
curseforge-token: ${{ secrets.CURSEFORGE_TOKEN }}
github-token: ${{ secrets.GITHUB_TOKEN }}
github-generate-changelog: true