Skip to content

Commit b1f8409

Browse files
Merge pull request #1 from hardingadonis/custom
Custom auto build script
2 parents 8bf74d4 + 3d86435 commit b1f8409

21 files changed

+314
-580
lines changed

.github/workflows/auto-release.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Auto release Revanced
2+
3+
on:
4+
push:
5+
branches: [main]
6+
7+
jobs:
8+
auto-release-revanced:
9+
name: Auto release Revanced
10+
runs-on: ubuntu-latest
11+
12+
permissions:
13+
contents: write
14+
15+
steps:
16+
- name: Checkout repository
17+
uses: actions/checkout@v3
18+
19+
- name: Setup JDK
20+
uses: actions/setup-java@v3
21+
with:
22+
distribution: zulu
23+
java-version: 17
24+
25+
- name: Setup Python
26+
uses: actions/setup-python@v4
27+
with:
28+
python-version: '3.10'
29+
- run: pip install -r requirements.txt
30+
31+
- name: Auto build Revanced
32+
run: python auto-build.py
33+
34+
- name: Set current date as env variable
35+
run: echo "date_now=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
36+
37+
- name: Auto release Revanced
38+
uses: softprops/action-gh-release@v0.1.15
39+
with:
40+
prerelease: false
41+
name: ${{ env.date_now }}
42+
tag_name: ${{ env.date_now }}
43+
generate_release_notes: true
44+
files: |
45+
build/*.apk
46+
revanced-tools/microg.apk

.github/workflows/experimental.yml

Lines changed: 0 additions & 39 deletions
This file was deleted.

.github/workflows/main.yml

Lines changed: 0 additions & 39 deletions
This file was deleted.

.github/workflows/test.yml

Lines changed: 0 additions & 35 deletions
This file was deleted.

.gitignore

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
*.apk
2-
*.jar
3-
apkeep
4-
*.dex
5-
revanced-cache/
1+
# Folders
2+
.venv/
63
build/
7-
.editorconfig
8-
patches.txt
9-
.vscode/
4+
downloaded/
5+
revanced-cache/
6+
revanced-tools/
7+
8+
# Files
9+
options.json

.pre-commit-config.yaml

Lines changed: 0 additions & 30 deletions
This file was deleted.

PATCHES_GUIDE.md

Lines changed: 0 additions & 47 deletions
This file was deleted.

README.md

Lines changed: 60 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,67 @@
1-
# Revanced Build
2-
This repo template will allow you to build ReVanced using Github Actions. This will helps people who don't want to setup build environments on their machines.
1+
# Revanced Auto Build
2+
[![Auto release Revanced](https://github.com/hardingadonis/revanced-auto-build/actions/workflows/auto-release.yml/badge.svg)](https://github.com/hardingadonis/revanced-auto-build/actions/workflows/auto-release.yml)
3+
[![Repository size](https://img.shields.io/github/repo-size/hardingadonis/revanced-auto-build)](https://github.com/hardingadonis/revanced-auto-build)
34

4-
## Notes
5-
- The script will download the **selected compatible version**([see here](versions.json)) of Youtube on APKMirror, **NOT** latest official version on Google Play.
6-
- Under **NO CIRCUMSTANCES** any APKs will be uploaded to this repository to avoid DMCA.
5+
> Auto build *Revanced (non-root)* for individual with GitHub Actions 😎😎
76
8-
## How to setup
9-
1. Fork or create a new repository using this repository as a template ([Guide](https://docs.github.com/en/repositories/creating-and-managing-repositories/creating-a-repository-from-a-template)). DO NOT FORK if you need to set the new repo to private.
10-
2. That's it! You can now build ReVanced using Github Actions.
7+
## Requirements
8+
- OS: Windows, MacOS or Linux.
9+
- Tools:
10+
- Python >= 3.10
11+
- JDK >= 17
1112

12-
## Customize your build
13-
If you wish to continue with the default settings, you may skip this step.
13+
## Setup
14+
- Step 1: Clone this repository
15+
```shell
16+
git clone https://github.com/hardingadonis/revanced-auto-build.git
17+
cd revanced-auto-build
18+
```
19+
- Step 2: Install **virtualenv**
20+
```shell
21+
pip install virtualenv
22+
```
23+
- Step 3: Install Python libraries
24+
```shell
25+
virtualenv .venv
26+
".venv/Scripts/activate"
27+
pip install -r requirements.txt
28+
```
29+
- Step 4: Run Python script
30+
```shell
31+
python auto-build.py
32+
```
1433

15-
All supported ReVanced apps are built by default by the script. If you wish to modify this behaviour and build only the apps that you specify, edit the 'build.targets' file with your preferred text editor. For the apps that you wish to be built, set the value of variable associated with the app to "true". Any variable with a value that is not "true" will be skip the associated app from being built.
34+
## Development
35+
> Just for those who want to build more Revanced apps.
1636
17-
For example, if you wish to skip TikTok ReVanced from being built, change the value of TIKTOK_NONROOT to "false".
37+
List all apps that Revanced support: [link](https://github.com/revanced/revanced-patches).
1838

19-
By default this will build ReVanced apps with ALL available patches. Follow [this guide](PATCHES_GUIDE.md) to exclude/customizing patches for your build.
39+
To add more app for building, check [packages.yml](packages.yml)
2040

21-
## How to build
22-
1. Go to Actions -> All workflows -> ReVanced Build ([Example](images/workflow_run.png))
23-
2. Run the `build` workflow (try to use `experimental_build` if the logs show not all patches applied correctly while revanced is not yet released)
24-
3. Download the APKs from the draft releases ([Example](images/build_release.png))
41+
Template:
42+
```yaml
43+
<the package name>:
44+
- version: <your version that you want to build>
45+
- uptodown: <link to download APK file from uptodown>
46+
- exclude_options:
47+
- <option 1>
48+
- <option 2>
49+
```
50+
51+
For example:
52+
```yaml
53+
com.google.android.youtube:
54+
- version: 18.16.37
55+
- uptodown: https://youtube.en.uptodown.com/android/download/101361605
56+
- exclude_options:
57+
- vanced-microg-support
58+
```
59+
60+
61+
## License
62+
63+
GPL-3.0 License,
64+
65+
Copyright (c) 2023 [Minh Vương](https://github.com/hardingadonis).
66+
67+
This repository is forked from [n0k0m3/revanced-build-template](https://github.com/n0k0m3/revanced-build-template), that also under **GPL-3.0 License**.

0 commit comments

Comments
 (0)