BaseBandRewrite/.forgejo/workflows/build-client.yml

61 lines
1.7 KiB
YAML
Raw Normal View History

2024-06-08 22:45:07 +02:00
on:
2024-06-08 22:47:42 +02:00
workflow_dispatch:
2024-06-08 22:45:07 +02:00
push:
paths:
2024-06-09 01:03:11 +02:00
- ".forgejo/workflows/build-client.yml"
2024-06-08 22:58:38 +02:00
- "Client/**"
2024-06-08 22:45:07 +02:00
2024-06-08 00:25:51 +02:00
jobs:
make:
2024-06-08 13:34:13 +02:00
name: Build BaseBand DSM & Broadway
2024-06-08 00:25:51 +02:00
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 Client:build Client:proguard
bash mobf.sh Client/build/proguard/BaseBand-DSM.jar
2024-06-09 01:03:11 +02:00
- name: Build Broadway
if: github.ref == 'refs/heads/release'
run: |
./gradlew Client:proguardRelease
bash mobf.sh Client/build/proguard/BaseBand-Broadway.jar
2024-06-08 13:34:13 +02:00
- name: Upload DSM
2024-06-08 00:25:51 +02:00
uses: forgejo/upload-artifact@v4
with:
name: BaseBand-DSM.jar
path: Client/build/libs/BaseBand-DSM.jar
2024-06-08 13:34:13 +02:00
- name: Upload Obfuscated DSM
uses: forgejo/upload-artifact@v4
with:
2024-06-08 23:16:45 +02:00
name: BaseBand-DSM-Standalone.jar
path: Client/build/proguard/BaseBand-DSM.jar
2024-06-09 01:03:11 +02:00
2024-06-08 22:45:07 +02:00
- name: Upload Broadway
2024-06-09 01:03:11 +02:00
if: github.ref == 'refs/heads/release'
2024-06-08 22:45:07 +02:00
uses: forgejo/upload-artifact@v4
with:
name: BaseBand-Broadway.jar
path: Client/build/proguard/BaseBand-Broadway.jar
- name: Release to server
if: github.ref == 'refs/heads/release'
2024-06-09 00:28:32 +02:00
env:
2024-06-09 12:08:48 +02:00
SSH_PRIVATEKEY: ${{ secrets.SSH_PRIVATEKEY }}
2024-06-09 00:28:32 +02:00
GPG_PRIVATEKEY: ${{ secrets.GPG_PRIVATEKEY }}
2024-06-09 03:26:18 +02:00
BB_HOST: ${{ vars.BB_HOST }}
2024-06-09 12:08:48 +02:00
BB_PORT: ${{ vars.BB_PORT }}
BB_PATH: ${{ vars.BB_PATH }}
2024-06-09 01:03:11 +02:00
run: bash push_file.sh Client/build/proguard/BaseBand-Broadway.jar 3849