wooohoo more actions
This commit is contained in:
parent
38d1f25234
commit
fa1ff87a22
5 changed files with 144 additions and 22 deletions
|
@ -1,4 +1,9 @@
|
|||
on: [push]
|
||||
on:
|
||||
push:
|
||||
paths:
|
||||
- "Client/"
|
||||
|
||||
|
||||
jobs:
|
||||
make:
|
||||
name: Build BaseBand DSM & Broadway
|
||||
|
@ -16,9 +21,7 @@ jobs:
|
|||
- name: Initialize Gradle
|
||||
uses: https://github.com/gradle/actions/setup-gradle@v3
|
||||
- name: Build
|
||||
run: ./gradlew --no-daemon Client:build
|
||||
- name: Obfuscate
|
||||
run: ./gradlew --no-daemon Client:proguard
|
||||
run: ./gradlew --no-daemon Client:build Client:proguard Client:proguardRelease
|
||||
- name: Upload DSM
|
||||
uses: forgejo/upload-artifact@v4
|
||||
with:
|
||||
|
@ -29,3 +32,8 @@ jobs:
|
|||
with:
|
||||
name: BaseBand-Standalone.jar
|
||||
path: Client/build/proguard/BaseBand-DSM.jar
|
||||
- name: Upload Broadway
|
||||
uses: forgejo/upload-artifact@v4
|
||||
with:
|
||||
name: BaseBand-Broadway.jar
|
||||
path: Client/build/proguard/BaseBand-Broadway.jar
|
||||
|
|
35
.forgejo/workflows/build-loader.yml
Normal file
35
.forgejo/workflows/build-loader.yml
Normal file
|
@ -0,0 +1,35 @@
|
|||
on:
|
||||
push:
|
||||
paths:
|
||||
- "Loader/"
|
||||
#- "Installer/"
|
||||
|
||||
|
||||
jobs:
|
||||
make:
|
||||
name: Build BaseBand Loader #& Installer
|
||||
|
||||
runs-on: 'docker'
|
||||
|
||||
steps:
|
||||
- name: Setup Java
|
||||
uses: https://github.com/actions/setup-java@v4
|
||||
with:
|
||||
distribution: 'adopt'
|
||||
java-version: 8
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- name: Initialize Gradle
|
||||
uses: https://github.com/gradle/actions/setup-gradle@v3
|
||||
- name: Build
|
||||
run: ./gradlew --no-daemon Loader:build Loader:proguard
|
||||
- name: Upload Loader
|
||||
uses: forgejo/upload-artifact@v4
|
||||
with:
|
||||
name: BaseBand-open.jar
|
||||
path: Client/build/libs/BaseBand-Loader.jar
|
||||
- name: Upload Obfuscated Loader
|
||||
uses: forgejo/upload-artifact@v4
|
||||
with:
|
||||
name: BaseBand.jar
|
||||
path: Client/build/proguard/BaseBand-Loader.jar
|
29
.forgejo/workflows/build-server.yml
Normal file
29
.forgejo/workflows/build-server.yml
Normal file
|
@ -0,0 +1,29 @@
|
|||
on:
|
||||
push:
|
||||
paths:
|
||||
- "Server/"
|
||||
|
||||
|
||||
jobs:
|
||||
make:
|
||||
name: Build BaseBand Server
|
||||
|
||||
runs-on: 'docker'
|
||||
|
||||
steps:
|
||||
- name: Setup Java
|
||||
uses: https://github.com/actions/setup-java@v4
|
||||
with:
|
||||
distribution: 'adopt'
|
||||
java-version: 8
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- name: Initialize Gradle
|
||||
uses: https://github.com/gradle/actions/setup-gradle@v3
|
||||
- name: Build
|
||||
run: ./gradlew --no-daemon Server:build
|
||||
- name: Upload Server
|
||||
uses: forgejo/upload-artifact@v4
|
||||
with:
|
||||
name: BaseBand-Server.jar
|
||||
path: Client/build/libs/BaseBand-Server.jar
|
|
@ -1,3 +1,11 @@
|
|||
|
||||
|
||||
String devName = "DSM"
|
||||
String releaseName = "Broadway"
|
||||
|
||||
|
||||
import proguard.gradle.ProGuardTask
|
||||
|
||||
buildscript {
|
||||
repositories {
|
||||
maven { url = 'https://maven.minecraftforge.net' }
|
||||
|
@ -133,36 +141,57 @@ jar {
|
|||
|
||||
baseName = ''
|
||||
version = ''
|
||||
classifier = 'BaseBand-DSM'
|
||||
classifier = "BaseBand-$devName"
|
||||
}
|
||||
|
||||
def proguardBuildDir = "${buildDir}/proguard"
|
||||
def proguardDir = "proguard"
|
||||
tasks.register('releaseJar', Jar) {
|
||||
|
||||
task proguard(type: proguard.gradle.ProGuardTask, dependsOn: jar) {
|
||||
configuration "${proguardDir}/proguard.cfg"
|
||||
injars jar.archiveFile
|
||||
outjars "${proguardBuildDir}/BaseBand-DSM.jar"
|
||||
libraryjars "${proguardDir}/rt.jar"
|
||||
libraryjars configurations.jarLibs
|
||||
dump "${proguardBuildDir}/dump.txt"
|
||||
printmapping "${proguardBuildDir}/mapping.txt"
|
||||
printconfiguration "${proguardBuildDir}/configuration.txt"
|
||||
}
|
||||
dependsOn jar
|
||||
|
||||
task releaseJar(type: Jar, dependsOn: jar) {
|
||||
from(zipTree(jar.archivePath)) {
|
||||
exclude 'com/baseband/client/DevStub.class'
|
||||
exclude 'com/baseband/client/DevStub.java'
|
||||
exclude 'org/'
|
||||
exclude 'org/spongepowered'
|
||||
}
|
||||
|
||||
manifest.attributes (
|
||||
manifest.attributes(
|
||||
'ReleaseJar': 'true'
|
||||
)
|
||||
baseName = ''
|
||||
version = ''
|
||||
classifier = 'BaseBand-Broadway'
|
||||
classifier = "BaseBand-$releaseName"
|
||||
}
|
||||
releaseJar.dependsOn(jar)
|
||||
build.dependsOn(releaseJar)
|
||||
|
||||
|
||||
def proguardBuildDir = "${buildDir}/proguard"
|
||||
def proguardDir = "proguard"
|
||||
|
||||
tasks.register('proguard', ProGuardTask) {
|
||||
|
||||
dependsOn jar
|
||||
|
||||
configuration "${proguardDir}/proguard.cfg"
|
||||
injars jar.archiveFile
|
||||
outjars "${proguardBuildDir}/BaseBand-${devName}.jar"
|
||||
libraryjars "${proguardDir}/rt.jar"
|
||||
libraryjars configurations.jarLibs
|
||||
dump "${proguardBuildDir}/dump-${devName}.txt"
|
||||
printmapping "${proguardBuildDir}/mapping-${devName}.txt"
|
||||
printconfiguration "${proguardBuildDir}/configuration.txt"
|
||||
}
|
||||
|
||||
build.dependsOn(releaseJar)
|
||||
tasks.register('proguardRelease', ProGuardTask) {
|
||||
|
||||
dependsOn tasks.releaseJar
|
||||
|
||||
configuration "${proguardDir}/proguard.cfg"
|
||||
injars tasks.releaseJar.archiveFile
|
||||
outjars "${proguardBuildDir}/BaseBand-${releaseName}.jar"
|
||||
libraryjars "${proguardDir}/rt.jar"
|
||||
libraryjars configurations.jarLibs
|
||||
dump "${proguardBuildDir}/dump-${releaseName}.txt"
|
||||
printmapping "${proguardBuildDir}/mapping-${releaseName}.txt"
|
||||
printconfiguration "${proguardBuildDir}/configuration.txt"
|
||||
}
|
|
@ -1,3 +1,6 @@
|
|||
|
||||
import proguard.gradle.ProGuardTask
|
||||
|
||||
buildscript {
|
||||
repositories {
|
||||
maven { url = 'https://maven.minecraftforge.net' }
|
||||
|
@ -7,6 +10,7 @@ buildscript {
|
|||
dependencies {
|
||||
classpath group: 'net.minecraftforge.gradle', name: 'ForgeGradle', version: '5.1.1', changing: true
|
||||
classpath "org.spongepowered:mixingradle:0.7.+"
|
||||
classpath 'com.guardsquare:proguard-gradle:7.1.0'
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -122,4 +126,21 @@ jar {
|
|||
} {
|
||||
exclude("mcmod.info")
|
||||
}
|
||||
}
|
||||
|
||||
def proguardBuildDir = "${buildDir}/proguard"
|
||||
def proguardDir = "proguard"
|
||||
|
||||
tasks.register('proguard', ProGuardTask) {
|
||||
|
||||
dependsOn jar
|
||||
|
||||
configuration "${proguardDir}/proguard.cfg"
|
||||
injars jar.archiveFile
|
||||
outjars "${proguardBuildDir}/BaseBand-Loader.jar"
|
||||
libraryjars "${proguardDir}/rt.jar"
|
||||
libraryjars configurations.jarLibs
|
||||
dump "${proguardBuildDir}/dump-Loader.txt"
|
||||
printmapping "${proguardBuildDir}/mapping-Loader.txt"
|
||||
printconfiguration "${proguardBuildDir}/configuration.txt"
|
||||
}
|
Loading…
Add table
Reference in a new issue