diff --git a/.github/workflows/loader-client.yaml b/.github/workflows/loader-client.yaml new file mode 100644 index 00000000..560cc524 --- /dev/null +++ b/.github/workflows/loader-client.yaml @@ -0,0 +1,34 @@ +on: + push: + branches: + - clean + +jobs: + loader-client: + name: Build Loader and Client + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-java@v4 + with: + distribution: 'temurin' + java-version: 8 + + - name: Setup Gradle + uses: gradle/gradle-build-action@v2 + + - name: Build Client + run: gradle client:build + + - name: Generate Client SHA Signature + run: gradle -p tools sig + + - name: Generate Loader + run: gradle loader:build + + - name: Upload a Build Artifact + uses: actions/upload-artifact@v3 + with: + name: loader-client + path: | + loader/build/libs/* diff --git a/tools/build.gradle b/tools/build.gradle index 9ea94095..09642380 100644 --- a/tools/build.gradle +++ b/tools/build.gradle @@ -10,3 +10,9 @@ tasks.withType(JavaCompile) { tasks.withType(JavaExec) { workingDir = rootProject.projectDir } + +tasks.register('sig', JavaExec) { + classpath = sourceSets.main.runtimeClasspath + main = 'lostcity.tools.LoaderSig' + args = ['client/build/libs/client.jar'] +} diff --git a/tools/src/main/java/lostcity/LoaderSig.java b/tools/src/main/java/lostcity/tools/LoaderSig.java similarity index 98% rename from tools/src/main/java/lostcity/LoaderSig.java rename to tools/src/main/java/lostcity/tools/LoaderSig.java index 082382fb..aa8628e0 100644 --- a/tools/src/main/java/lostcity/LoaderSig.java +++ b/tools/src/main/java/lostcity/tools/LoaderSig.java @@ -1,4 +1,4 @@ -package lostcity; +package lostcity.tools; import java.nio.file.Files; import java.nio.file.Paths;