commit b3d0d4231cf026834b7043019f8d7b9d614d6d6a Author: Buduf Date: Sat Mar 30 18:02:34 2024 +0100 v19.09.37 diff --git a/.gitea/workflows/build.yml b/.gitea/workflows/build.yml new file mode 100644 index 0000000..830879e --- /dev/null +++ b/.gitea/workflows/build.yml @@ -0,0 +1,68 @@ +name: Build +on: [push] + +jobs: + build: + name: Build + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Create tag + run: git tag ${{ github.event.head_commit.message }} && git push --tags + + - name: Setup Java + uses: actions/setup-java@v4 + with: + distribution: 'zulu' + java-version: '11' + + - name: Install jq + run: apt update && apt install jq -y + + - name: Get version code + id: vars + run: | + echo "version_code=$(cat versionCode.txt)" >> $GITHUB_OUTPUT + + - name: Get youtube apk + run: | + wget "https://d.apkpure.net/b/APK/com.google.android.youtube?versionCode=${{ steps.vars.outputs.version_code }}" \ + --progress=dot:style:mega \ + -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 --progress=dot:style:mega -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 --progress=dot -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 --progress=dot -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 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..1060a31 --- /dev/null +++ b/build.sh @@ -0,0 +1,25 @@ +#!/bin/bash + +versionCode=$(cat versionCode.txt) + +wget "https://d.apkpure.net/b/APK/com.google.android.youtube?versionCode=${versionCode}" \ + --progress=dot:style:mega + -O input.apk + +curl -s https://api.github.com/repos/ReVanced/revanced-cli/releases/latest | \ + jq --raw-output '.assets[0] | .browser_download_url' | \ + wget --progress=dot:style:mega -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