mirror of
https://github.com/ReVanced/revanced-cli.git
synced 2026-01-18 00:43:58 +00:00
Compare commits
40 Commits
v2.21.0-de
...
v2.21.5-de
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e5e768fa34 | ||
|
|
9082181ce5 | ||
|
|
542580ecff | ||
|
|
26112a4fd2 | ||
|
|
553fbdbb8f | ||
|
|
be429a4770 | ||
|
|
8c391cecce | ||
|
|
bd14bdb5ea | ||
|
|
d0fc886428 | ||
|
|
1ccbed8d17 | ||
|
|
3b89fb7bc2 | ||
|
|
16bb1a60fc | ||
|
|
5f1843771e | ||
|
|
9de90703c8 | ||
|
|
1201f9edc5 | ||
|
|
9c8f9608b2 | ||
|
|
be90d2e360 | ||
|
|
79dc99aa9b | ||
|
|
260ff00951 | ||
|
|
cfe4c5ed0e | ||
|
|
7133242691 | ||
|
|
55750ce16a | ||
|
|
6003e68d47 | ||
|
|
9f8c2aeedf | ||
|
|
0a16bc849b | ||
|
|
ecd5147590 | ||
|
|
ca255c9e1b | ||
|
|
e9aa490355 | ||
|
|
69fe59f97b | ||
|
|
995e1712bc | ||
|
|
a236f10bb0 | ||
|
|
4a6134ea60 | ||
|
|
b084024742 | ||
|
|
2ef48af1b3 | ||
|
|
da2c91874d | ||
|
|
379687c814 | ||
|
|
2f5577e464 | ||
|
|
6962fc2f4c | ||
|
|
a6cef26210 | ||
|
|
b4892c4413 |
23
.github/workflows/release.yml
vendored
23
.github/workflows/release.yml
vendored
@@ -23,17 +23,20 @@ jobs:
|
|||||||
# https://github.com/cycjimmy/semantic-release-action#private-packages
|
# https://github.com/cycjimmy/semantic-release-action#private-packages
|
||||||
persist-credentials: false
|
persist-credentials: false
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
- name: Setup JDK
|
- name: Cache
|
||||||
uses: actions/setup-java@v3
|
uses: actions/cache@v3
|
||||||
with:
|
with:
|
||||||
java-version: '17'
|
path: |
|
||||||
distribution: 'zulu'
|
${{ runner.home }}/.gradle/caches
|
||||||
cache: gradle
|
${{ runner.home }}/.gradle/wrapper
|
||||||
- name: Setup Node.js
|
.gradle
|
||||||
uses: actions/setup-node@v3
|
build
|
||||||
with:
|
node_modules
|
||||||
node-version: "18"
|
key: ${{ runner.os }}-gradle-npm-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties', 'package-lock.json') }}
|
||||||
cache: 'npm'
|
- name: Build with Gradle
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
run: ./gradlew clean --no-daemon
|
||||||
- name: Setup semantic-release
|
- name: Setup semantic-release
|
||||||
run: npm install
|
run: npm install
|
||||||
- name: Release
|
- name: Release
|
||||||
|
|||||||
@@ -7,7 +7,13 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"plugins": [
|
"plugins": [
|
||||||
"@semantic-release/commit-analyzer",
|
[
|
||||||
|
"@semantic-release/commit-analyzer", {
|
||||||
|
"releaseRules": [
|
||||||
|
{ "type": "build", "scope": "revanced-patcher", "release": "patch" }
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
"@semantic-release/release-notes-generator",
|
"@semantic-release/release-notes-generator",
|
||||||
"@semantic-release/changelog",
|
"@semantic-release/changelog",
|
||||||
"gradle-semantic-release-plugin",
|
"gradle-semantic-release-plugin",
|
||||||
|
|||||||
60
CHANGELOG.md
60
CHANGELOG.md
@@ -1,15 +1,67 @@
|
|||||||
# [2.21.0-dev.1](https://github.com/revanced/revanced-cli/compare/v2.20.2-dev.1...v2.21.0-dev.1) (2023-05-04)
|
## [2.21.5-dev.2](https://github.com/revanced/revanced-cli/compare/v2.21.5-dev.1...v2.21.5-dev.2) (2023-07-01)
|
||||||
|
|
||||||
|
## [2.21.5-dev.1](https://github.com/revanced/revanced-cli/compare/v2.21.4...v2.21.5-dev.1) (2023-06-27)
|
||||||
|
|
||||||
|
## [2.21.4](https://github.com/revanced/revanced-cli/compare/v2.21.3...v2.21.4) (2023-06-21)
|
||||||
|
|
||||||
|
|
||||||
### Bug Fixes
|
### Bug Fixes
|
||||||
|
|
||||||
* **tests:** set order of tests ([816f9d6](https://github.com/revanced/revanced-cli/commit/816f9d668cb738e6a27c28249a65f85037309993))
|
* remove duplicate options entries. ([d0fc886](https://github.com/revanced/revanced-cli/commit/d0fc8864286adc2677f91a319a11a90272c1001d))
|
||||||
* use working JADB dependency version ([#222](https://github.com/revanced/revanced-cli/issues/222)) ([33c6565](https://github.com/revanced/revanced-cli/commit/33c65655a4afb8a17ed368166538f4f50ce3af3a))
|
|
||||||
|
## [2.21.4-dev.1](https://github.com/revanced/revanced-cli/compare/v2.21.3...v2.21.4-dev.1) (2023-06-18)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* remove duplicate options entries. ([d0fc886](https://github.com/revanced/revanced-cli/commit/d0fc8864286adc2677f91a319a11a90272c1001d))
|
||||||
|
|
||||||
|
## [2.21.3](https://github.com/revanced/revanced-cli/compare/v2.21.2...v2.21.3) (2023-06-12)
|
||||||
|
|
||||||
|
## [2.21.3-dev.1](https://github.com/revanced/revanced-cli/compare/v2.21.2...v2.21.3-dev.1) (2023-06-07)
|
||||||
|
|
||||||
|
## [2.21.2](https://github.com/revanced/revanced-cli/compare/v2.21.1...v2.21.2) (2023-05-24)
|
||||||
|
|
||||||
|
## [2.21.2-dev.2](https://github.com/revanced/revanced-cli/compare/v2.21.2-dev.1...v2.21.2-dev.2) (2023-05-15)
|
||||||
|
|
||||||
|
## [2.21.2-dev.1](https://github.com/revanced/revanced-cli/compare/v2.21.1...v2.21.2-dev.1) (2023-05-07)
|
||||||
|
|
||||||
|
## [2.21.1](https://github.com/revanced/revanced-cli/compare/v2.21.0...v2.21.1) (2023-05-06)
|
||||||
|
|
||||||
|
## [2.21.1-dev.1](https://github.com/revanced/revanced-cli/compare/v2.21.0...v2.21.1-dev.1) (2023-05-06)
|
||||||
|
|
||||||
|
# [2.21.0](https://github.com/revanced/revanced-cli/compare/v2.20.2...v2.21.0) (2023-05-04)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* **tests:** set order of tests ([2ef48af](https://github.com/revanced/revanced-cli/commit/2ef48af1b339ab729a05d69cb0c8c1ee1e3ab486))
|
||||||
|
* use working JADB dependency version ([#222](https://github.com/revanced/revanced-cli/issues/222)) ([da2c918](https://github.com/revanced/revanced-cli/commit/da2c91874d5623402febfcc0677ada3d648565e1))
|
||||||
|
|
||||||
|
|
||||||
### Features
|
### Features
|
||||||
|
|
||||||
* add appreciation message for new contributors ([a78d646](https://github.com/revanced/revanced-cli/commit/a78d646afc2cf4e2fa19fbb89416e0a3f6ba559a))
|
* add appreciation message for new contributors ([6962fc2](https://github.com/revanced/revanced-cli/commit/6962fc2f4c0f0c96e88a823be64f8ebd1312ee17))
|
||||||
|
|
||||||
|
# [2.21.0-dev.1](https://github.com/revanced/revanced-cli/compare/v2.20.2...v2.21.0-dev.1) (2023-05-04)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* **tests:** set order of tests ([2ef48af](https://github.com/revanced/revanced-cli/commit/2ef48af1b339ab729a05d69cb0c8c1ee1e3ab486))
|
||||||
|
* use working JADB dependency version ([#222](https://github.com/revanced/revanced-cli/issues/222)) ([da2c918](https://github.com/revanced/revanced-cli/commit/da2c91874d5623402febfcc0677ada3d648565e1))
|
||||||
|
|
||||||
|
|
||||||
|
### Features
|
||||||
|
|
||||||
|
* add appreciation message for new contributors ([6962fc2](https://github.com/revanced/revanced-cli/commit/6962fc2f4c0f0c96e88a823be64f8ebd1312ee17))
|
||||||
|
|
||||||
|
## [2.20.2](https://github.com/revanced/revanced-cli/compare/v2.20.1...v2.20.2) (2023-04-30)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* correct spelling mistake ([31fb316](https://github.com/revanced/revanced-cli/commit/31fb3166d922ae1f568f52e44cbe726dd1c891a4))
|
||||||
|
|
||||||
## [2.20.2-dev.1](https://github.com/revanced/revanced-cli/compare/v2.20.1...v2.20.2-dev.1) (2023-04-03)
|
## [2.20.2-dev.1](https://github.com/revanced/revanced-cli/compare/v2.20.1...v2.20.2-dev.1) (2023-04-03)
|
||||||
|
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ repositories {
|
|||||||
dependencies {
|
dependencies {
|
||||||
implementation("org.jetbrains.kotlin:kotlin-reflect:1.8.20-RC")
|
implementation("org.jetbrains.kotlin:kotlin-reflect:1.8.20-RC")
|
||||||
|
|
||||||
implementation("app.revanced:revanced-patcher:7.0.0")
|
implementation("app.revanced:revanced-patcher:11.0.3")
|
||||||
implementation("info.picocli:picocli:4.7.1")
|
implementation("info.picocli:picocli:4.7.1")
|
||||||
implementation("com.github.revanced:jadb:2531a28109") // updated fork
|
implementation("com.github.revanced:jadb:2531a28109") // updated fork
|
||||||
implementation("com.android.tools.build:apksig:8.1.0-alpha09")
|
implementation("com.android.tools.build:apksig:8.1.0-alpha09")
|
||||||
@@ -34,6 +34,10 @@ dependencies {
|
|||||||
testImplementation("org.jetbrains.kotlin:kotlin-test:1.8.20-RC")
|
testImplementation("org.jetbrains.kotlin:kotlin-test:1.8.20-RC")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
kotlin {
|
||||||
|
jvmToolchain(11)
|
||||||
|
}
|
||||||
|
|
||||||
tasks {
|
tasks {
|
||||||
test {
|
test {
|
||||||
useJUnitPlatform()
|
useJUnitPlatform()
|
||||||
|
|||||||
@@ -1,17 +1,15 @@
|
|||||||
# 💼 Prerequisites
|
# 💼 Prerequisites
|
||||||
|
|
||||||
To use the ReVanced CLI, you will need to fulfill certain requirements.
|
To use ReVanced CLI, you will need to fulfill certain requirements.
|
||||||
|
|
||||||
## 🤝 Requirements
|
## 🤝 Requirements
|
||||||
|
|
||||||
- [Android Debug Bridge (adb)](https://developer.android.com/studio/command-line/adb), the command-line tool that lets
|
- Java SDK 11 (Azul JDK or OpenJDK)
|
||||||
you communicate with a device (optional).
|
- [Android Debug Bridge (adb)](https://developer.android.com/studio/command-line/adb) if you want to deploy the patched APK file on your device
|
||||||
- A x86/x86_64 host (or a custom AAPT binary for your architecture)
|
- An ABI other than ARMv7 such as x86 or x86-64 (or a custom AAPT binary that supports ARMv7)
|
||||||
- Zulu OpenJDK 17
|
|
||||||
- An APK file (e.g. YouTube v17.49.37 or YouTube Music v5.36.51)
|
|
||||||
|
|
||||||
## ⏭️ Whats next
|
## ⏭️ Whats next
|
||||||
|
|
||||||
The next section will show, how to use the [ReVanced CLI](https://github.com/revanced/revanced-cli).
|
The next section will show, how to use [ReVanced CLI](https://github.com/revanced/revanced-cli).
|
||||||
|
|
||||||
Continue: [🛠️ Using the ReVanced CLI](1_usage.md)
|
Continue: [🛠️ Using ReVanced CLI](1_usage.md)
|
||||||
|
|||||||
@@ -1,74 +1,76 @@
|
|||||||
# 🛠️ Using the ReVanced CLI
|
# 🛠️ Using ReVanced CLI
|
||||||
|
|
||||||
Learn how to use the ReVanced CLI.
|
Learn how to ReVanced CLI.
|
||||||
|
|
||||||
## ⚡ Setup (optional)
|
## ⚡ Setup ADB
|
||||||
|
|
||||||
1. Make sure your device is connected
|
1. Ensure that ADB is working
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
adb shell exit
|
adb shell exit
|
||||||
```
|
```
|
||||||
|
|
||||||
If you plan to use the root variant, check if you have root access
|
If you want to deploy the patched APK file on your device by mounting it on top of the original APK file, you will need root access. This is optional.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
adb shell su -c exit
|
adb shell su -c exit
|
||||||
```
|
```
|
||||||
|
|
||||||
2. Copy the ADB device name
|
2. Get the name of your device
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
adb devices
|
adb devices
|
||||||
```
|
```
|
||||||
|
|
||||||
## 🔨 ReVanced CLI Usage
|
## 🔨 Using ReVanced CLI
|
||||||
|
|
||||||
- ### Show all available options for the ReVanced CLI
|
- ### ⚙️ Show all available options for ReVanced CLI
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
java -jar revanced-cli.jar -h
|
java -jar revanced-cli.jar -h
|
||||||
```
|
```
|
||||||
|
|
||||||
- ### List all available patches from supplied patch bundles
|
- ### 📃 List all available patches from supplied patch bundles
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
java -jar revanced-cli.jar \
|
java -jar revanced-cli.jar
|
||||||
-b revanced-patches.jar \
|
-b revanced-patches.jar \
|
||||||
-l
|
-l
|
||||||
```
|
```
|
||||||
|
|
||||||
- ### Use the ReVanced CLI without root permissions
|
- ### 💉 Use ReVanced CLI to patch an APK file but deploy without root permissions
|
||||||
|
|
||||||
|
This will deploy the patched APK file on your device by installing it.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
java -jar revanced-cli.jar \
|
java -jar revanced-cli.jar \
|
||||||
-a input.apk \
|
-a input.apk \
|
||||||
-o patched-output.apk \
|
-o patched-output.apk \
|
||||||
-b revanced-patches.jar
|
-b revanced-patches.jar \
|
||||||
|
-d device-name
|
||||||
```
|
```
|
||||||
|
|
||||||
- ### Mount the patched application with root permissions over the installed application
|
- ### 👾 Use ReVanced CLI to patch an APK file but deploy with root permissions
|
||||||
|
|
||||||
|
This will deploy the patched APK file on your device by mounting it on top of the original APK file.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
adb install input.apk # make sure the same version is installed
|
adb install input.apk
|
||||||
java -jar revanced-cli.jar \
|
java -jar revanced-cli.jar \
|
||||||
-a input.apk \
|
-a input.apk \
|
||||||
-d device-name \
|
|
||||||
-o patched-output.apk \
|
-o patched-output.apk \
|
||||||
-b revanced-patches.jar \
|
-b revanced-patches.jar \
|
||||||
-e vanced-microg-support \
|
-e vanced-microg-support \
|
||||||
|
-d device-name \
|
||||||
--mount
|
--mount
|
||||||
```
|
```
|
||||||
|
|
||||||
> **Note**:
|
> **Note**: Some patches from [ReVanced Patches](https://github.com/revanced/revanced-patches) also require [ReVanced Integrations](https://github.com/revanced/revanced-integrations). Supply them with the option `-m`. ReVanced Patcher will merge ReVanced Integrations automatically, depending on if the supplied patches require them.
|
||||||
>
|
|
||||||
> - If you want to exclude patches, you can use the option `-e`. In the case of YouTube, you can exclude
|
- ### ⚙️ Supply options to patches using ReVanced CLI
|
||||||
the `vanced-microg-support` patch from [ReVanced Patches](https://github.com/revanced/revanced-patches) with the
|
|
||||||
option `-e vanced-microg-support` when mounting for example.
|
Some patches provide options. Currently, ReVanced CLI will generate and consume an `options.json` file at the location that is specified in `-o`. If the option is not specified, the options file will be generated in the current working directory.
|
||||||
>
|
|
||||||
> - Some patches from [ReVanced Patches](https://github.com/revanced/revanced-patches) also might require
|
The options file contains all options from supplied patch bundles.
|
||||||
[ReVanced Integrations](https://github.com/revanced/revanced-integrations). Supply them with the option `-m`.
|
|
||||||
> The integrations will be merged, if necessary automatically, if supplied.
|
> **Note**: The `options.json` file will be generated at the first time you use ReVanced CLI to patch an APK file for now. This will be changed in the future.
|
||||||
>
|
|
||||||
> - If you supplied a device with the option `-d`, the patched application will be automatically installed on the
|
|
||||||
device.
|
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
# 💻 Documentation and guides of ReVanced CLI
|
# 💻 Documentation and guides of ReVanced CLI
|
||||||
|
|
||||||
This documentation explains how to use the [ReVanced CLI](https://github.com/revanced/revanced-cli).
|
This documentation explains how to use [ReVanced CLI](https://github.com/revanced/revanced-cli).
|
||||||
|
|
||||||
## 📖 Table of contents
|
## 📖 Table of contents
|
||||||
|
|
||||||
1. [💼 Prerequisites](0_prerequisites.md)
|
1. [💼 Prerequisites](0_prerequisites.md)
|
||||||
2. [🛠️ Using the ReVanced CLI](1_usage.md)
|
2. [🛠️ Using ReVanced CLI](1_usage.md)
|
||||||
|
|||||||
@@ -1,2 +1,2 @@
|
|||||||
kotlin.code.style = official
|
kotlin.code.style = official
|
||||||
version = 2.21.0-dev.1
|
version = 2.21.5-dev.2
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import app.revanced.cli.logging.CliLogger
|
|||||||
import app.revanced.patcher.extensions.PatchExtensions.options
|
import app.revanced.patcher.extensions.PatchExtensions.options
|
||||||
import app.revanced.patcher.extensions.PatchExtensions.patchName
|
import app.revanced.patcher.extensions.PatchExtensions.patchName
|
||||||
import app.revanced.patcher.patch.NoSuchOptionException
|
import app.revanced.patcher.patch.NoSuchOptionException
|
||||||
|
import app.revanced.utils.Options.PatchOption.Option
|
||||||
import com.fasterxml.jackson.module.kotlin.jacksonObjectMapper
|
import com.fasterxml.jackson.module.kotlin.jacksonObjectMapper
|
||||||
import java.io.File
|
import java.io.File
|
||||||
|
|
||||||
@@ -25,9 +26,12 @@ internal object Options {
|
|||||||
.map { patch ->
|
.map { patch ->
|
||||||
PatchOption(
|
PatchOption(
|
||||||
patch.patchName,
|
patch.patchName,
|
||||||
patch.options!!.map { option -> PatchOption.Option(option.key, option.value) }
|
patch.options!!.map { option -> Option(option.key, option.value) }
|
||||||
)
|
)
|
||||||
}.let {
|
}
|
||||||
|
// See https://github.com/revanced/revanced-patches/pull/2434/commits/60e550550b7641705e81aa72acfc4faaebb225e7.
|
||||||
|
.distinctBy { it.patchName }
|
||||||
|
.let {
|
||||||
if (prettyPrint)
|
if (prettyPrint)
|
||||||
mapper.writerWithDefaultPrettyPrinter().writeValueAsString(it)
|
mapper.writerWithDefaultPrettyPrinter().writeValueAsString(it)
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user