2024-03-03 19:33:25 +01:00
|
|
|
name: Publish mod on Modrinth
|
|
|
|
|
|
|
|
on: [ push, workflow_dispatch ]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: checkout repository
|
|
|
|
uses: actions/checkout@v3
|
|
|
|
- name: validate gradle wrapper
|
2024-03-03 22:53:30 +01:00
|
|
|
uses: gradle/wrapper-validation-action@v2
|
2024-03-03 19:33:25 +01:00
|
|
|
- name: setup jdk
|
|
|
|
uses: actions/setup-java@v3
|
|
|
|
with:
|
|
|
|
java-version: 17
|
|
|
|
distribution: 'oracle'
|
|
|
|
- name: make gradle wrapper executable
|
|
|
|
if: ${{ runner.os != 'Windows' }}
|
|
|
|
run: |
|
|
|
|
chmod +x ./gradlew
|
|
|
|
touch local.properties
|
|
|
|
- name: Generate data
|
|
|
|
run: ./gradlew runDatagen
|
|
|
|
- name: Publish Modrinth
|
|
|
|
run: ./gradlew modrinth
|
|
|
|
env:
|
2024-03-03 22:53:30 +01:00
|
|
|
MODRINTH_TOKEN: ${{ secrets.MODRINTH_TOKEN }}
|