commit cc16f82de9e40e80dd03b38e624ea7537504a812 Author: Buduf Date: Sat Mar 30 15:57:26 2024 +0100 v19.09.37 diff --git a/.gitea/workflows/build.yml b/.gitea/workflows/build.yml new file mode 100644 index 0000000..6fa0ece --- /dev/null +++ b/.gitea/workflows/build.yml @@ -0,0 +1,63 @@ +name: Build +on: [push] + +jobs: + build: + name: Build + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Setup Java + uses: actions/setup-java@v4 + with: + distribution: 'temurin' + java-version: '21' + + - name: Get version code + id: vars + run: | + echo "version_code=$(cat versinoCode.txt)" >> $GITEA_OUTPUT + + - name: Get youtube apk + run: | + wget "https://d.apkpure.net/b/APK/com.google.android.youtube?versionCode=${{ steps.vars.outputs.version_code }}" -O input.apk + + - name: Get revanced-cli + run: | + curl -s https://api.github.com/repos/ReVanced/revanced-cli/releases/latest | \ + jq --raw-output '.assets[0] | .browser_download_url' | \ + wget -i - -O revanced-cli.jar + + - name: Get revanced-patches + run: | + curl -s https://api.github.com/repos/ReVanced/revanced-patches/releases/latest | \ + jq --raw-output '.assets[1] | .browser_download_url' | \ + wget -i - -O revanced-patches.jar + + - name: Get revanced-integrations + run: | + curl -s https://api.github.com/repos/ReVanced/revanced-integrations/releases/latest | \ + jq --raw-output '.assets[0] | .browser_download_url' | \ + wget -i - -O revanced-integrations.apk + + - name: Build youtube-revacned + run: | + java -jar revanced-cli.jar patch \ + -b revanced-patches.jar \ + -m revanced-integrations.apk \ + -o youtube-revanced.apk \ + input.apk + + - name: Create tag + run: git tag "${{ github.event.head_commit.message }}" + + - name: Create release + uses: akkuman/gitea-release-action@v1 + env: + NODE_OPTIONS: '--experimental-fetch' + with: + files: |- + youtube-revanced.apk diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a1403ad --- /dev/null +++ b/.gitignore @@ -0,0 +1,6 @@ +revanced-cli.jar +revanced-patches.jar +revanced-integrations.apk +input.apk + +youtube-revanced* diff --git a/build.sh b/build.sh new file mode 100755 index 0000000..698fae7 --- /dev/null +++ b/build.sh @@ -0,0 +1,23 @@ +#!/bin/bash + +versionCode=$(cat versionCode.txt) + +wget "https://d.apkpure.net/b/APK/com.google.android.youtube?versionCode=${versionCode}" -O input.apk + +curl -s https://api.github.com/repos/ReVanced/revanced-cli/releases/latest | \ + jq --raw-output '.assets[0] | .browser_download_url' | \ + wget -i - -O revanced-cli.jar + +curl -s https://api.github.com/repos/ReVanced/revanced-patches/releases/latest | \ + jq --raw-output '.assets[1] | .browser_download_url' | \ + wget -i - -O revanced-patches.jar + +curl -s https://api.github.com/repos/ReVanced/revanced-integrations/releases/latest | \ + jq --raw-output '.assets[0] | .browser_download_url' | \ + wget -i - -O revanced-integrations.apk + +java -jar revanced-cli.jar patch \ + -b revanced-patches.jar \ + -m revanced-integrations.apk \ + -o youtube-revanced.apk \ + input.apk diff --git a/versionCode.txt b/versionCode.txt new file mode 100644 index 0000000..f62e457 --- /dev/null +++ b/versionCode.txt @@ -0,0 +1 @@ +1544809920