Skip to content

🤶🏻 6.1.0 - Advent #44

🤶🏻 6.1.0 - Advent

🤶🏻 6.1.0 - Advent #44

Workflow file for this run

name: Release
on:
release:
types: [published]
workflow_dispatch:
jobs:
release-ubuntu:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Java
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
- name: Setup Ubuntu
continue-on-error: true
run: sudo apt-get install -y fuse3; sudo apt-get install -y fuse
- name: Create Sekrets
run: |
./gradlew createSekretProperties -Pkey=GITHUB_CLIENT_ID -Pvalue=${{ secrets.GH_CLIENT_ID }};
./gradlew createSekretProperties -Pkey=GITHUB_CLIENT_SECRET -Pvalue=${{ secrets.GH_CLIENT_SECRET }};
./gradlew createSekretProperties -Pkey=FIREBASE_PROJECT -Pvalue=${{ secrets.FIREBASE_PROJECT }};
./gradlew createSekretProperties -Pkey=FIREBASE_APPLICATION -Pvalue=${{ secrets.FIREBASE_APPLICATION }};
./gradlew createSekretProperties -Pkey=FIREBASE_API_KEY -Pvalue=${{ secrets.FIREBASE_API_KEY }}
- name: Generate Sekrets
run: ./gradlew composeApp:generateSekret
- name: Build Sekret binary
run: ./gradlew composeApp:createSekretNativeBinary
- name: Copy Sekrets
run: ./gradlew composeApp:copySekretNativeBinary
- name: Build
continue-on-error: true
run: ./gradlew build
- name: Create debian package on Ubuntu
continue-on-error: true
run: ./gradlew composeApp:packageDeb
- name: Create AppImage on Ubuntu
continue-on-error: true
run: ./gradlew composeApp:packageAppImage; ./gradlew composeApp:packageUberJarForCurrentOS
- name: Create uber jar on Ubuntu
continue-on-error: true
run: ./gradlew composeApp:packageUberJarForCurrentOS
- name: Create Browser Extensions on Ubuntu
continue-on-error: true
run: ./gradlew extension:packChromium; ./gradlew extension:packFirefox
- name: Create AppImage and Tarball
continue-on-error: true
run: |
mkdir -p ./build/release/main/image/Burning-Series/usr
curl --request GET --url https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-x86_64.AppImage --location --output ./build/release/main/image/appimagetool.AppImage
curl --request GET --url https://github.com/AppImage/AppImageKit/releases/download/continuous/AppRun-x86_64 --location --output ./build/release/main/image/Burning-Series/AppRun
chmod +x ./build/release/main/image/appimagetool.AppImage
chmod +x ./build/release/main/image/Burning-Series/AppRun
cp ./composeApp/Burning-Series.desktop ./build/release/main/image/Burning-Series/
cp ./build/release/main/app/Burning-Series/lib/Burning-Series.png ./build/release/main/image/Burning-Series/
cp -r ./build/release/main/app/Burning-Series/bin ./build/release/main/image/Burning-Series/usr/
cp -r ./build/release/main/app/Burning-Series/lib ./build/release/main/image/Burning-Series/usr/
./build/release/main/image/appimagetool.AppImage ./build/release/main/image/Burning-Series ./build/release/main/image/Burning-Series-${{ github.ref_name }}-x86_64.AppImage
tar cJf ./build/release/main/app/Burning-Series.tar.xz ./build/release/main/app/Burning-Series
- name: Upload release packages
uses: softprops/action-gh-release@v1
with:
files: |
./build/release/main/app/Burning-Series.tar.xz
./build/release/main/image/Burning-Series-${{ github.ref_name }}-x86_64.AppImage
./build/release/main/deb/*.deb
./build/release/main/extension/*.zip
./build/release/main/extension/*.xpi
./composeApp/build/compose/jars/Burning-Series-*.jar
release-windows:
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Java
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
- name: Create Sekrets
run: |
gradle createSekretProperties -Pkey=GITHUB_CLIENT_ID -Pvalue=${{ secrets.GH_CLIENT_ID }};
gradle createSekretProperties -Pkey=GITHUB_CLIENT_SECRET -Pvalue=${{ secrets.GH_CLIENT_SECRET }};
gradle createSekretProperties -Pkey=FIREBASE_PROJECT -Pvalue=${{ secrets.FIREBASE_PROJECT }};
gradle createSekretProperties -Pkey=FIREBASE_APPLICATION -Pvalue=${{ secrets.FIREBASE_APPLICATION }};
gradle createSekretProperties -Pkey=FIREBASE_API_KEY -Pvalue=${{ secrets.FIREBASE_API_KEY }}
working-directory: ${{ github.workspace }}
- name: Generate Sekrets
run: gradle composeApp:generateSekret
- name: Build Sekret binary
run: gradle composeApp:createSekretNativeBinary
working-directory: ${{ github.workspace }}
- name: Copy Sekrets
run: gradle composeApp:copySekretNativeBinary
working-directory: ${{ github.workspace }}
- name: Build
continue-on-error: true
run: gradle build
working-directory: ${{ github.workspace }}
- name: Package executable
continue-on-error: true
run: gradle composeApp:packageExe
working-directory: ${{ github.workspace }}
- name: Package MSI
run: gradle composeApp:packageMsi
working-directory: ${{ github.workspace }}
- name: Package uber jar
run: gradle composeApp:packageUberJarForCurrentOS
working-directory: ${{ github.workspace }}
- name: Upload release packages
uses: softprops/action-gh-release@v1
with:
files: |
build/release/main/exe/*.exe
build/release/main/msi/*.msi
composeApp/build/compose/jars/Burning-Series-*.jar
release-mac:
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Java
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
- name: Create Sekrets
run: |
./gradlew createSekretProperties -Pkey=GITHUB_CLIENT_ID -Pvalue=${{ secrets.GH_CLIENT_ID }};
./gradlew createSekretProperties -Pkey=GITHUB_CLIENT_SECRET -Pvalue=${{ secrets.GH_CLIENT_SECRET }};
./gradlew createSekretProperties -Pkey=FIREBASE_PROJECT -Pvalue=${{ secrets.FIREBASE_PROJECT }};
./gradlew createSekretProperties -Pkey=FIREBASE_APPLICATION -Pvalue=${{ secrets.FIREBASE_APPLICATION }};
./gradlew createSekretProperties -Pkey=FIREBASE_API_KEY -Pvalue=${{ secrets.FIREBASE_API_KEY }}
- name: Generate Sekrets
run: ./gradlew composeApp:generateSekret
- name: Build Sekret binary
run: ./gradlew composeApp:createSekretNativeBinary
- name: Copy Sekrets
run: ./gradlew composeApp:copySekretNativeBinary
- name: Build
continue-on-error: true
run: ./gradlew build
- name: Package DMG
continue-on-error: true
run: ./gradlew composeApp:packageDmg
- name: Package uber jar
continue-on-error: true
run: ./gradlew composeApp:packageUberJarForCurrentOS
- name: Upload release packages
uses: softprops/action-gh-release@v1
with:
files: |
./build/release/main/dmg/*.dmg
./composeApp/build/compose/jars/Burning-Series-*.jar
release-android:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Java
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
- name: Create Sekrets
run: |
./gradlew createSekretProperties -Pkey=GITHUB_CLIENT_ID -Pvalue=${{ secrets.GH_CLIENT_ID }};
./gradlew createSekretProperties -Pkey=GITHUB_CLIENT_SECRET -Pvalue=${{ secrets.GH_CLIENT_SECRET }};
./gradlew createSekretProperties -Pkey=FIREBASE_PROJECT -Pvalue=${{ secrets.FIREBASE_PROJECT }};
./gradlew createSekretProperties -Pkey=FIREBASE_APPLICATION -Pvalue=${{ secrets.FIREBASE_APPLICATION }};
./gradlew createSekretProperties -Pkey=FIREBASE_API_KEY -Pvalue=${{ secrets.FIREBASE_API_KEY }}
- name: Generate Sekrets
run: ./gradlew composeApp:generateSekret
- name: Build Sekret binary
run: ./gradlew composeApp:createSekretNativeBinary
- name: Copy Sekrets
run: ./gradlew composeApp:copySekretNativeBinary
- name: Build
continue-on-error: true
run: ./gradlew build
- name: Package
run: ./gradlew composeApp:assembleRelease && ./gradlew composeApp:bundleRelease
- name: Move APK file(s)
run: mv ./composeApp/build/outputs/apk/release/*.apk ./composeApp/release/
- name: Move AAB file(s)
run: mv ./composeApp/build/outputs/bundle/release/*.aab ./composeApp/release/
- name: Remove "-unsigned" from filename(s)
run: for filename in ./composeApp/release/*-unsigned*; do mv "./$filename" "./$(echo "$filename" | sed -e 's/-unsigned//g')"; done
- uses: ilharp/sign-android-release@v1
id: sign_app
with:
releaseDir: composeApp/release
signingKey: ${{ secrets.ANDROID_SIGNING_KEY }}
keyAlias: ${{ secrets.ANDROID_KEY_ALIAS }}
keyStorePassword: ${{ secrets.ANDROID_KEYSTORE_PASSWORD }}
keyPassword: ${{ secrets.ANDROID_KEY_PASSWORD }}
- name: Split signed files
uses: xom9ikk/split@v1
id: split
with:
string: ${{ steps.sign_app.outputs.signedFiles }}
separator: ':'
limit: 2
- name: Release
uses: softprops/action-gh-release@v1
with:
files: |
${{ steps.split.outputs._0 }}
${{ steps.split.outputs._1 }}