diff --git a/.github/workflows/modrinth.yml b/.github/workflows/modrinth.yml new file mode 100644 index 0000000..1d898d5 --- /dev/null +++ b/.github/workflows/modrinth.yml @@ -0,0 +1,38 @@ +name: Modrinth + +on: + release: + types: + - published + +permissions: + contents: read + +jobs: + build: + environment: Build + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + with: + submodules: true + token: ${{ secrets.PAT_TOKEN }} + - name: Set up JDK 17 + uses: actions/setup-java@v3 + with: + java-version: '17' + distribution: 'temurin' + # Taken from https://github.com/CaffeineMC/sodium-fabric/blob/1.19.3/dev/.github/workflows/gradle.yml + - name: Cache/Uncache + uses: actions/cache@v2 + with: + path: | + ~/.gradle/caches + ~/.gradle/loom-cache + ~/.gradle/wrapper + key: ${{ runner.os }}-gradle-${{ hashFiles('**/gradle-wrapper.properties') }} + restore-keys: | + ${{ runner.os }}-gradle- + - name: Build artifacts + run: ./gradlew modrinth \ No newline at end of file