Skip to content

Commit

Permalink
Build: Enable GitHub Actions based CI
Browse files Browse the repository at this point in the history
Also removes 1.15 because of a bug in archloom ([1]).
Diff between 1.16.2-forge before and after the removal shows no significant
changes.

[1]: architectury/architectury-loom#151
  • Loading branch information
Johni0702 committed Sep 11, 2023
1 parent 7d0c9f4 commit f40ddc5
Show file tree
Hide file tree
Showing 6 changed files with 50 additions and 19 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Build & Publish

on:
push:
branches:
- master
pull_request:

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-java@v3
with:
distribution: temurin
java-version: |
8
16
17
cache: gradle

- name: Setup environment
run: |
echo "ORG_GRADLE_PROJECT_BUILD_ID=$(expr ${{ github.run_number }} + 290)" >> "$GITHUB_ENV"
# GitHub runners are limited to 7GB of RAM, so we'll limit our Gradle Daemon process to about half of that
# which is enough so long as parallel task execution is limited.
# We also pin the amount of workers, so it doesn't break should GitHub increase the default available vCPUs.
# We write these to GRADLE_USER_HOME to overrule the local "gradle.properties" of the project.
mkdir -p "${GRADLE_USER_HOME:=~/.gradle}"
echo "org.gradle.jvmargs=-Xmx4G" >> "$GRADLE_USER_HOME/gradle.properties"
echo "org.gradle.workers.max=2" >> "$GRADLE_USER_HOME/gradle.properties"
- name: Build
run: ./gradlew build --stacktrace

- name: Publish
run: echo ./gradlew publish --stacktrace
if: env.NEXUS_USER != null
env:
NEXUS_USER: ${{ secrets.NEXUS_USER }}
NEXUS_PASSWORD: ${{ secrets.NEXUS_PASSWORD }}
1 change: 1 addition & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ org.gradle.parallel=true
org.gradle.configureoncommand=true
org.gradle.parallel.threads=4
org.gradle.jvmargs=-Xmx8G
# cache buster comment
4 changes: 1 addition & 3 deletions root.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ preprocess {
val fabric11701 = createNode("1.17.1-fabric", 11701, "yarn")
val fabric11602 = createNode("1.16.2-fabric", 11602, "yarn")
val forge11602 = createNode("1.16.2-forge", 11602, "srg")
val forge11502 = createNode("1.15.2-forge", 11502, "srg")
val forge11202 = createNode("1.12.2-forge", 11202, "srg")
val forge10809 = createNode("1.8.9-forge", 10809, "srg")

Expand All @@ -46,7 +45,6 @@ preprocess {
forge11701.link(fabric11701)
fabric11701.link(fabric11602, file("versions/1.17.1-1.16.2.txt"))
fabric11602.link(forge11602)
forge11602.link(forge11502, file("versions/1.16.2-1.15.2.txt"))
forge11502.link(forge11202, file("versions/1.15.2-1.12.2.txt"))
forge11602.link(forge11202, file("versions/1.16.2-1.12.2.txt"))
forge11202.link(forge10809, file("versions/1.12.2-1.8.9.txt"))
}
1 change: 0 additions & 1 deletion settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ rootProject.buildFileName = "root.gradle.kts"
listOf(
"1.8.9-forge",
"1.12.2-forge",
"1.15.2-forge",
"1.16.2-forge",
"1.16.2-fabric",
"1.17.1-fabric",
Expand Down
17 changes: 6 additions & 11 deletions versions/1.15.2-1.12.2.txt → versions/1.16.2-1.12.2.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ net.minecraft.util.SoundEvents net.minecraft.init.SoundEvents
net.minecraft.client.renderer.texture.Texture net.minecraft.client.renderer.texture.AbstractTexture
net.minecraft.resources.IResourceManager net.minecraft.client.resources.IResourceManager
net.minecraft.client.renderer.texture.TextureUtil prepareImage() allocateTexture()
net.minecraft.client.renderer.Matrix3f org.lwjgl.util.vector.Matrix3f
net.minecraft.client.renderer.Matrix4f org.lwjgl.util.vector.Matrix4f
net.minecraft.client.renderer.Matrix4f write() org.lwjgl.util.vector.Matrix4f store()
net.minecraft.client.renderer.Quaternion org.lwjgl.util.vector.Quaternion
net.minecraft.client.renderer.Vector3f org.lwjgl.util.vector.Vector3f
net.minecraft.client.renderer.Vector4f org.lwjgl.util.vector.Vector4f
net.minecraft.util.math.vector.Matrix3f org.lwjgl.util.vector.Matrix3f
net.minecraft.util.math.vector.Matrix4f org.lwjgl.util.vector.Matrix4f
net.minecraft.util.math.vector.Matrix4f write() org.lwjgl.util.vector.Matrix4f store()
net.minecraft.util.math.vector.Quaternion org.lwjgl.util.vector.Quaternion
net.minecraft.util.math.vector.Vector3f org.lwjgl.util.vector.Vector3f
net.minecraft.util.math.vector.Vector4f org.lwjgl.util.vector.Vector4f
net.minecraft.client.gui.screen.Screen net.minecraft.client.gui.GuiScreen
net.minecraft.client.gui.widget.Widget net.minecraft.client.gui.GuiButton
net.minecraft.client.renderer.entity.RenderPlayer net.minecraft.client.renderer.entity.PlayerRenderer
Expand All @@ -32,8 +32,3 @@ net.minecraft.client.GameSettings net.minecraft.client.settings.GameSettings
net.minecraft.client.gui.NewChatGui net.minecraft.client.gui.GuiNewChat
net.minecraft.client.gui.screen.MainMenuScreen net.minecraft.client.gui.GuiMainMenu
net.minecraft.network.play.server.SChatPacket net.minecraft.network.play.server.SPacketChat





4 changes: 0 additions & 4 deletions versions/1.16.2-1.15.2.txt

This file was deleted.

0 comments on commit f40ddc5

Please sign in to comment.