Skip to content

MM24.7.1

MM24.7.1 #19

Workflow file for this run

name: 1.12.2 Build
on:
pull_request:
push:
branches:
- "mainline"
env:
WORLDMAP_VERSION: "1.39.2"
MINIMAP_VERSION: "24.7.1"
MINECRAFT_VERSION: "1.12.2"
MINECRAFT_VERSION_SHORT: "1.12"
MOD_LOADER: "Forge"
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Gradle Wrapper Verification
uses: gradle/actions/wrapper-validation@v4
- name: Set up JDK 8
uses: actions/setup-java@v4
with:
java-version: '8'
distribution: 'temurin'
- name: Elevate wrapper permissions
run: chmod +x ./gradlew
- name: Build mod
run: ./gradlew build
- name: Get Forge Jar Filename
run: echo "XP_FORGE=XaeroPlus-${{ github.run_number }}+forge-${{ env.MINECRAFT_VERSION }}-WM${{ env.WORLDMAP_VERSION }}-MM${{ env.MINIMAP_VERSION }}" >> $GITHUB_ENV
- name: Rename built mod
run: mv build/libs/xaeroplus-${{ env.MINECRAFT_VERSION }}.jar ${{ env.XP_FORGE }}.jar
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: ${{ env.XP_FORGE }}
path: ${{ env.XP_FORGE }}.jar
outputs:
xp_forge: ${{ env.XP_FORGE }}
test-forge:
runs-on: ubuntu-latest
needs:
- build
steps:
- name: Set up JDK 8
uses: actions/setup-java@v4
with:
java-version: '8'
distribution: 'temurin'
- name: Download job artifacts
uses: actions/download-artifact@v4
with:
merge-multiple: true
path: artifacts/
- name: Set CI Test Env Var
run: echo "XP_CI_TEST=true" >> $GITHUB_ENV
- name: Setup Forge Test
run: |
mkdir -p run/mods && cp artifacts/${{ needs.build.outputs.xp_forge }}.jar run/mods \
&& wget https://api.modrinth.com/maven/maven/modrinth/xaeros-minimap/${{ env.MINIMAP_VERSION }}_Forge_1.12/xaeros-minimap-${{ env.MINIMAP_VERSION }}_Forge_1.12.jar -P run/mods/ \
&& wget https://api.modrinth.com/maven/maven/modrinth/xaeros-world-map/${{ env.WORLDMAP_VERSION }}_Forge_1.12/xaeros-world-map-${{ env.WORLDMAP_VERSION }}_Forge_1.12.jar -P run/mods/ \
&& wget https://api.modrinth.com/maven/maven/modrinth/mixinbooter/9.4/!mixinbooter-9.4.jar -P run/mods/
- name: Forge Test
uses: headlesshq/mc-runtime-test@3.0.0
with:
mc: ${{ env.MINECRAFT_VERSION }}
modloader: forge
regex: .*forge.*
mc-runtime-test: lexforge
java: 8
xvfb: false
headlessmc-command: -lwjgl --jvm -Djava.awt.headless=true
cache-mc: true