Skip to content

Release: Nightly 5.5.2 #41

Release: Nightly 5.5.2

Release: Nightly 5.5.2 #41

Workflow file for this run

name: Nightly Build
on:
push:
branches: master
paths:
- 'app/build.gradle'
workflow_dispatch:
jobs:
release_desktop:
strategy:
matrix:
platform: [ windows-latest, ubuntu-latest]
# platform: [ windows-latest, ubuntu-latest, macos-latest, macos-13]
runs-on: ${{ matrix.platform }}
if: startsWith(github.event.head_commit.message, 'Release:')
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Node.js setup
uses: actions/setup-node@v4
with:
node-version: latest
- name: Get npm cache directory
id: npm-cache-dir
shell: bash
run: echo "dir=$(npm config get cache)" >> ${GITHUB_OUTPUT}
- name: Initialize cache
uses: actions/cache@v4
id: npm-cache # use this to check for `cache-hit` ==> if: steps.npm-cache.outputs.cache-hit != 'true'
with:
path: ${{ steps.npm-cache-dir.outputs.dir }}
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install app dependencies
run: npm install
# - name: Build app (MacOS - arm64)
# if: matrix.platform == 'macos-latest'
# run: npm run build-mac
# - name: Upload build (MacOS - arm64)
# uses: actions/upload-artifact@v4
# if: matrix.platform == 'macos-latest'
# with:
# name: animetv-mac-arm64.dmg
# path: ./electron/builds/animetv-darwin-arm64/*.dmg
# - name: Build app (MacOS - x64)
# if: matrix.platform == 'macos-13'
# run: npm run build-mac-x64
# - name: Upload build (MacOS - x64)
# uses: actions/upload-artifact@v4
# if: matrix.platform == 'macos-13'
# with:
# name: animetv-mac-x64.dmg
# path: ./electron/builds/animetv-darwin-x64/*.dmg
- name: Build app (Windows - x64)
if: matrix.platform == 'windows-latest'
run: npm run build-win
- name: Upload build windows installer (Windows - x64)
uses: actions/upload-artifact@v4
if: matrix.platform == 'windows-latest'
with:
name: animetv-win32-x64.exe
path: ./electron/builds/*.exe
- name: Upload build windows portable (Windows - x64)
uses: actions/upload-artifact@v4
if: matrix.platform == 'windows-latest'
with:
name: animetv-win32-x64-portable
path: ./electron/builds/AnimeTV-win32-x64
- name: Upload build windows portable (Windows - arm64)
uses: actions/upload-artifact@v4
if: matrix.platform == 'windows-latest'
with:
name: animetv-win32-arm64-portable
path: ./electron/builds/AnimeTV-win32-arm64
- name: Upload build windows update app.asar (Windows - x64)
uses: actions/upload-artifact@v4
if: matrix.platform == 'windows-latest'
with:
name: animetv-win32-x64-update.asar
path: ./electron/builds/AnimeTV-win32-x64/resources
- name: Build app (Linux - x64 & arm64)
if: matrix.platform == 'ubuntu-latest'
run: npm run build-linux && npm run build-linux-arm64
- name: Upload build deb (Linux - x64)
uses: actions/upload-artifact@v4
if: matrix.platform == 'ubuntu-latest'
with:
name: animetv-linux-x64.deb
path: ./electron/builds/*_amd64.deb
- name: Upload build rpm (Linux - x64)
uses: actions/upload-artifact@v4
if: matrix.platform == 'ubuntu-latest'
with:
name: animetv-linux-x64.rpm
path: ./electron/builds/*.x86_64.rpm
- name: Upload build linux portable (Linux - x64)
uses: actions/upload-artifact@v4
if: matrix.platform == 'ubuntu-latest'
with:
name: animetv-linux-x64-portable
path: ./electron/builds/animetv-linux-x64
- name: Upload build linux update app.asar (Linux - x64)
uses: actions/upload-artifact@v4
if: matrix.platform == 'ubuntu-latest'
with:
name: animetv-linux-x64-update.asar
path: ./electron/builds/animetv-linux-x64/resources
- name: Upload build deb (Linux - arm64)
uses: actions/upload-artifact@v4
if: matrix.platform == 'ubuntu-latest'
with:
name: animetv-linux-arm64.deb
path: ./electron/builds/*_aarch64.deb
- name: Upload build rpm (Linux - arm64)
uses: actions/upload-artifact@v4
if: matrix.platform == 'ubuntu-latest'
with:
name: animetv-linux-arm64.rpm
path: ./electron/builds/*.aarch64.rpm
- name: Upload build linux portable (Linux - arm64)
uses: actions/upload-artifact@v4
if: matrix.platform == 'ubuntu-latest'
with:
name: animetv-linux-arm64-portable
path: ./electron/builds/animetv-linux-arm64
- name: Upload build linux update app.asar (Linux - arm64)
uses: actions/upload-artifact@v4
if: matrix.platform == 'ubuntu-latest'
with:
name: animetv-linux-arm64-update.asar
path: ./electron/builds/animetv-linux-arm64/resources
release_mobile:
runs-on: ubuntu-latest
if: startsWith(github.event.head_commit.message, 'Release:')
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Setup Java
uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: 17
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
- name: Prepare Gradle
run: |
echo "${{ secrets.RELEASE_KEYSTORE }}" > release.keystore.asc
gpg -d --passphrase "${{ secrets.RELEASE_PASSWORD }}" --batch release.keystore.asc > keystore/debug.keystore
chmod +x ./gradlew
- name: Build Apk
run: ./gradlew assembleRelease
- name: Upload build (Android)
uses: actions/upload-artifact@v4
with:
name: animetv-android.apk
path: ./app/build/outputs/apk/release/*.apk
- name: Draft release
uses: marvinpinto/action-automatic-releases@latest
if: startsWith(github.event.head_commit.message, 'Release:v')
with:
repo_token: "${{ secrets.RELEASE_TOKEN }}"
automatic_release_tag: "latest"
draft: true
title: "Dev Release ${{ env.date_now }}"
files: ./app/build/outputs/apk/release/*.apk