diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 4ececb6..6f574a2 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -26,6 +26,7 @@ jobs: run: | chmod +x gradlew ./gradlew build + - name: Upload artifacts (fabric) uses: actions/upload-artifact@v3 with: @@ -36,3 +37,9 @@ jobs: with: name: forge path: ${{ github.workspace }}/forge/build/libs + + - name: Upload artifacts (Forgix merged jar) + uses: actions/upload-artifact@v3 + with: + name: merged + path: ${{ github.workspace }}/build/libs/forgix diff --git a/build.gradle b/build.gradle index 4853902..ca6f0be 100644 --- a/build.gradle +++ b/build.gradle @@ -1,5 +1,6 @@ plugins { id "architectury-plugin" version "3.4-SNAPSHOT" + id "io.github.pacifistmc.forgix" version "1.2.6" id "dev.architectury.loom" version "1.3-SNAPSHOT" apply false } @@ -42,3 +43,19 @@ allprojects { withSourcesJar() } } + +forgix { + group = rootProject.maven_group + mergedJarName = "${rootProject.archives_base_name}-${project.version}.jar" + outputDir = "build/libs/forgix" + + forge { + projectName = "forge" + jarLocation = "build/libs/${rootProject.archives_base_name}-forge-${ rootProject.version }.jar" + } + + fabric { + projectName = "fabric" + jarLocation = "build/libs/${rootProject.archives_base_name}-fabric-${ rootProject.version }.jar" + } +}