From 334745ef2d4dc5b4b72bee1ad50c88addf2829bc Mon Sep 17 00:00:00 2001 From: Arkai1 Date: Wed, 16 Apr 2025 18:15:52 +0530 Subject: [PATCH] Update hianime-build.yml --- .github/workflows/hianime-build.yml | 42 ++++++++++++++++++----------- 1 file changed, 26 insertions(+), 16 deletions(-) diff --git a/.github/workflows/hianime-build.yml b/.github/workflows/hianime-build.yml index be64afff..7d4de87a 100644 --- a/.github/workflows/hianime-build.yml +++ b/.github/workflows/hianime-build.yml @@ -10,24 +10,34 @@ jobs: runs-on: ubuntu-latest steps: - - name: Checkout source branch - uses: actions/checkout@v3 + - name: Checkout source branch + uses: actions/checkout@v3 - - name: Set up JDK - uses: actions/setup-java@v3 - with: - distribution: 'temurin' - java-version: '17' + - name: Set up JDK + uses: actions/setup-java@v3 + with: + distribution: 'temurin' + java-version: '17' - - name: Grant permission to Gradle - run: chmod +x ./gradlew + - name: Grant permission to Gradle + run: chmod +x ./gradlew - - name: Build Hianime APK - run: ./gradlew :src:en:zoro:assembleDebug + - name: Build Hianime APK + run: ./gradlew :src:en:zoro:assembleDebug - - name: Copy APK to temporary folder - run: | - mkdir -p out/apk/Hianime - cp src/en/zoro/build/outputs/apk/debug/*.apk out/apk/Hianime/ + - name: Copy APK to output folder + run: | + mkdir -p out/apk/Hianime + cp src/en/zoro/build/outputs/apk/debug/*.apk out/apk/Hianime/ - - name: Push APK to apk + - name: Push APK to apk-builds branch + run: | + cd out + git init + git config user.name "GitHub Actions" + git config user.email "github-actions@users.noreply.github.com" + git add . + git commit -m "Update Hianime APK [CI build]" + git branch -M apk-builds + git remote add origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git + git push -f origin apk-builds