Skip to content

WM1.35.0 MM23.8.3

WM1.35.0 MM23.8.3 #60

Workflow file for this run

name: Fabric 1.20.1 Build And Release
on:
push:
branches:
- "fabric-1.20.1"
env:
WORLDMAP_VERSION: "1.35.0"
MINIMAP_VERSION: "23.8.3"
MINECRAFT_VERSION: "1.20.1"
MINECRAFT_VERSION_SHORT: "1.20"
MOD_LOADER: "Fabric"
FABRIC_API_VERSION: "0.90.0+1.20.1"
FABRIC_API_MODRINTH_VERSION_ID: "tFw0iWAk"
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Gradle Wrapper Verification
uses: gradle/wrapper-validation-action@v1
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'
- name: Elevate wrapper permissions
run: chmod +x ./gradlew
- name: Build mod
run: ./gradlew build
- name: Rename built mod
run: mv build/libs/xaeroplus-${{ env.MINECRAFT_VERSION }}.jar XaeroPlus-${{ env.MOD_LOADER }}-${{ env.MINECRAFT_VERSION }}-${{ github.run_number }}-WM${{ env.WORLDMAP_VERSION }}-MM${{ env.MINIMAP_VERSION }}.jar
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: ${{ env.MOD_LOADER }}-${{ env.MINECRAFT_VERSION }}-${{ github.run_number }}-WM${{ env.WORLDMAP_VERSION }}-MM${{ env.MINIMAP_VERSION }}
path: XaeroPlus-${{ env.MOD_LOADER }}-${{ env.MINECRAFT_VERSION }}-${{ github.run_number }}-WM${{ env.WORLDMAP_VERSION }}-MM${{ env.MINIMAP_VERSION }}.jar
- name: Download Xaero WorldMap
run: wget https://chocolateminecraft.com/mods2/worldmap/XaerosWorldMap_${{ env.WORLDMAP_VERSION }}_${{ env.MOD_LOADER }}_${{ env.MINECRAFT_VERSION_SHORT }}.jar --no-check-certificate
- name: Download Xaero Minimap
run: wget https://chocolateminecraft.com/mods2/minimap/Xaeros_Minimap_${{ env.MINIMAP_VERSION }}_${{ env.MOD_LOADER }}_${{ env.MINECRAFT_VERSION_SHORT }}.jar --no-check-certificate
- name: Download Fabric API
run: wget https://cdn.modrinth.com/data/P7dR8mSH/versions/${{ env.FABRIC_API_MODRINTH_VERSION_ID }}/fabric-api-${{ env.FABRIC_API_VERSION }}.jar --no-check-certificate
- name: Create modpack zip
run: >
zip -j
XaeroPlus-modpack-${{ env.MOD_LOADER }}-${{ env.MINECRAFT_VERSION }}-${{ github.run_number }}.zip
XaeroPlus-${{ env.MOD_LOADER }}-${{ env.MINECRAFT_VERSION }}-${{ github.run_number }}-WM${{ env.WORLDMAP_VERSION }}-MM${{ env.MINIMAP_VERSION }}.jar
XaerosWorldMap_${{ env.WORLDMAP_VERSION }}_${{ env.MOD_LOADER }}_${{ env.MINECRAFT_VERSION_SHORT }}.jar
Xaeros_Minimap_${{ env.MINIMAP_VERSION }}_${{ env.MOD_LOADER }}_${{ env.MINECRAFT_VERSION_SHORT }}.jar
fabric-api-${{ env.FABRIC_API_VERSION }}.jar
- name: Upload modpack artifact
uses: actions/upload-artifact@v3
with:
name: XaeroPlus-modpack-${{ env.MOD_LOADER }}-${{ env.MINECRAFT_VERSION }}-${{ github.run_number }}
path: XaeroPlus-modpack-${{ env.MOD_LOADER }}-${{ env.MINECRAFT_VERSION }}-${{ github.run_number }}.zip
# todo: for future auto-update check feature
# - name: Create version identifier file
# run: echo ${{ github.run_number }} > version.txt
- name: Get Previous Release Number
env:
THIS_RUN_NUMBER: ${{ github.run_number }}
run: |
echo "PREV_RUN_NUMBER=$(($THIS_RUN_NUMBER - 1))" >> "$GITHUB_ENV"
- name: Generate changelog
id: changelog
uses: metcalfc/changelog-generator@v4.1.0
with:
myToken: ${{ secrets.GITHUB_TOKEN }}
base-ref: ${{ env.MOD_LOADER }}-${{ env.MINECRAFT_VERSION }}-${{ env.PREV_RUN_NUMBER }}
- name: Release
uses: Kir-Antipov/mc-publish@v3.3
with:
changelog: ${{steps.changelog.outputs.changelog}}
curseforge-token: ${{ secrets.CURSEFORGE_TOKEN }}
curseforge-id: 866084
modrinth-token: ${{ secrets.MODRINTH_TOKEN }}
modrinth-id: EnPUzSTg
github-token: ${{ secrets.GITHUB_TOKEN }}
github-files: |
XaeroPlus-${{ env.MOD_LOADER }}-${{ env.MINECRAFT_VERSION }}-${{ github.run_number }}-WM${{ env.WORLDMAP_VERSION }}-MM${{ env.MINIMAP_VERSION }}.jar
XaeroPlus-modpack-${{ env.MOD_LOADER }}-${{ env.MINECRAFT_VERSION }}-${{ github.run_number }}.zip
github-tag: ${{ env.MOD_LOADER }}-${{ env.MINECRAFT_VERSION }}-${{ github.run_number }}
github-commitish: fabric-1.20.1
files: |
XaeroPlus-${{ env.MOD_LOADER }}-${{ env.MINECRAFT_VERSION }}-${{ github.run_number }}-WM${{ env.WORLDMAP_VERSION }}-MM${{ env.MINIMAP_VERSION }}.jar
name: ${{ env.MOD_LOADER }}-${{ env.MINECRAFT_VERSION }}-${{ github.run_number }}-WM${{ env.WORLDMAP_VERSION }}-MM${{ env.MINIMAP_VERSION }}
version: ${{ github.run_number }}
loaders: |
${{ env.MOD_LOADER }}
quilt
game-versions: |
${{ env.MINECRAFT_VERSION }}
dependencies: |
xaerominimap@${{ env.MINIMAP_VERSION }}(required){modrinth:1bokaNcj}{curseforge:263420}
xaeroworldmap@${{ env.WORLDMAP_VERSION }}(required){modrinth:NcUtCpym}{curseforge:317780}
fabric-api@${{ env.FABRIC_API_VERSION }}(required){modrinth:P7dR8mSH}{curseforge:306612}