Compare commits

...

7 Commits

Author SHA1 Message Date
semantic-release-bot
7ea5d87fa2 chore(release): 2.12.1 [skip ci]
## [2.12.1](https://github.com/revanced/revanced-patches/compare/v2.12.0...v2.12.1) (2022-07-10)
2022-07-10 16:14:45 +00:00
TheJeterLP
471a3d3263 build: fix readme autogeneration not working 2022-07-10 18:12:52 +02:00
bogadana
b95fe30c78 docs: templated readme (#138) 2022-07-10 15:28:18 +02:00
semantic-release-bot
cb0cf342c0 chore(release): 2.12.0 [skip ci]
# [2.12.0](https://github.com/revanced/revanced-patches/compare/v2.11.0...v2.12.0) (2022-07-10)

### Bug Fixes

* update patches to `17.26.35` ([#142](https://github.com/revanced/revanced-patches/issues/142)) ([11db0f4](11db0f49c9))
* wording [skip ci] ([017ef1f](017ef1fb88))

### Features

* issue templates ([0991fbc](0991fbc9e8))
2022-07-10 05:38:19 +00:00
bogadana
11db0f49c9 fix: update patches to 17.26.35 (#142) 2022-07-10 07:36:43 +02:00
oSumAtrIX
017ef1fb88 fix: wording [skip ci] 2022-07-10 00:31:01 +02:00
oSumAtrIX
0991fbc9e8 feat: issue templates 2022-07-10 00:27:29 +02:00
34 changed files with 156 additions and 52 deletions

24
.github/ISSUE_TEMPLATE/bug-report.md vendored Normal file
View File

@@ -0,0 +1,24 @@
---
name: Bug report
about: Create a bug report on patches
title: 'problem: `some-patch`'
labels: bug
assignees: TheJeterLP, oSumAtrIX, Sculas
---
# 🐞 Issue
<!-- Describe your issue in detail here -->
# ⚙ Reproduce
<!-- Include your environment and steps to reproduce the issue as detailed as possible -->
# 🛠 Solution
<!-- If applicable, add a possible solution -->
# ⚠ Additional context
<!-- Add any other context about the problem here -->

View File

@@ -0,0 +1,24 @@
---
name: Feature request
about: Suggest a change to some patch. Do not submit suggestions for patches here.
title: 'feat: some feature'
labels: feature-request
assignees: TheJeterLP, oSumAtrIX, Sculas
---
# 🐞 Issue
<!-- Explain here, what the current problem is and why it lead you to request a feature change -->
# ❗ Solution
<!-- Explain how your current issue can be solved -->
# ❓ Motivation
<!-- Explain why your feature should be considered -->
# ⚠ Additional context
<!-- Add any other context or screenshots about the feature request here -->

View File

@@ -33,7 +33,7 @@ jobs:
- name: Build with Gradle
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: ./gradlew build clean
run: ./gradlew build clean generateReadme
- name: Install Android build-tools
run: sdkmanager "build-tools;32.0.0"
- name: Setup semantic-release

View File

@@ -1,3 +1,18 @@
## [2.12.1](https://github.com/revanced/revanced-patches/compare/v2.12.0...v2.12.1) (2022-07-10)
# [2.12.0](https://github.com/revanced/revanced-patches/compare/v2.11.0...v2.12.0) (2022-07-10)
### Bug Fixes
* update patches to `17.26.35` ([#142](https://github.com/revanced/revanced-patches/issues/142)) ([b04112c](https://github.com/revanced/revanced-patches/commit/b04112c8562a7b95e7555e894b665913094b33eb))
* wording [skip ci] ([ba64d9e](https://github.com/revanced/revanced-patches/commit/ba64d9efc3ee606e9bda30ad7f8017af34b1dc3f))
### Features
* issue templates ([b82b0aa](https://github.com/revanced/revanced-patches/commit/b82b0aad88b7ab9d86f1bcc8e007f6a76a9aa1a5))
# [2.11.0](https://github.com/revanced/revanced-patches/compare/v2.10.2...v2.11.0) (2022-07-09)

8
README-template.md Normal file
View File

@@ -0,0 +1,8 @@
# ReVanced Patches
🧩 Official patches by ReVanced
# Patch list
| 💊 Patch | 📜 Description | 🎯 Target Package | 🏹 Target Version |
|:--------:|:--------------:|:-----------------:|:-----------------:|
{{ table }}

View File

@@ -1,2 +1,35 @@
# ReVanced Patches
🧩 Official patches by ReVanced
# Patch list
| 💊 Patch | 📜 Description | 🎯 Target Package | 🏹 Target Version |
|:--------:|:--------------:|:-----------------:|:-----------------:|
|Fenster Swipe Controls|Adds volume and brightness swipe controls.|`com.google.android.youtube`|17.26.35|
|Seekbar Tapping|Enables tapping on the seekbar of the YouTube player.|`com.google.android.youtube`|17.26.35|
|General Ads|Removes general ads in bytecode.|`com.google.android.youtube`|17.26.35|
|Video Ads|Removes ads in the YouTube video player.|`com.google.android.youtube`|17.26.35|
|Hide Infocard Suggestions|Hides infocards in videos.|`com.google.android.youtube`|17.26.35|
|Autorepeat By Default|Enables auto repeating of videos by default.|`com.google.android.youtube`|17.26.35|
|Custom Branding|Changes the branding of YouTube.|`com.google.android.youtube`|all|
|Premium Heading|Shows premium branding on the YouTube home screen.|`com.google.android.youtube`|all|
|Minimized Playback|Enables minimized and background playback.|`com.google.android.youtube`|17.26.35|
|Enable Wide Searchbar|Replaces the search icon with a wide search bar. This will hide the YouTube logo when active.|`com.google.android.youtube`|17.26.35|
|Disable Fullscreen Panels|Disables comments panel in fullscreen view.|`com.google.android.youtube`|17.26.35|
|Old Quality Layout|Enables the original quality flyout menu.|`com.google.android.youtube`|17.26.35|
|Hide Autoplay Button|Disables the autoplay button.|`com.google.android.youtube`|17.26.35|
|Disable Create Button|Disables the create button.|`com.google.android.youtube`|17.26.35|
|Amoled|Enables pure black theme.|`com.google.android.youtube`|17.26.35|
|Hide Shorts Button|Hides the shorts button.|`com.google.android.youtube`|17.26.35|
|Hide Cast Button|Hides the cast button.|`com.google.android.youtube`|all|
|Hide Watermark|Hides the creator's watermark on videos.|`com.google.android.youtube`|17.26.35|
|Microg Support|Allows YouTube ReVanced to run without root and under a different package name.|`com.google.android.youtube`|17.26.35|
|Custom Playback Speed|Allows to change the default playback speed options.|`com.google.android.youtube`|17.26.35|
|Hdr Max Brightness|Sets brightness to max for HDR videos in fullscreen mode.|`com.google.android.youtube`|17.26.35|
|Enable Debugging|Enables app debugging by patching the manifest file.|`com.google.android.youtube`|all|
|Background Play|Enables playing music in the background.|`com.google.android.apps.youtube.music`|5.03.50|
|Exclusive Audio Playback|Adds the option to play music without video.|`com.google.android.apps.youtube.music`|5.03.50|
|Codecs Unlock|Enables more audio codecs. Usually results in better audio quality but may depend on song and device.|`com.google.android.apps.youtube.music`|5.03.50|
|Upgrade Button Remover|Removes the upgrade tab from the pivot bar in YouTube music.|`com.google.android.apps.youtube.music`|5.03.50|
|TasteBuilder Remover|Removes the "Tell us which artists you like" card from the Home screen. The same functionality can be triggered from the settings anyway.|`com.google.android.apps.youtube.music`|5.03.50|

View File

@@ -54,7 +54,7 @@ tasks {
dependsOn(build)
classpath = sourceSets["main"].runtimeClasspath
mainClass.set("app.revanced.patches.meta.ReadmeGenerator")
mainClass.set("app.revanced.patches.meta.readme.Generator")
}
// Dummy task to fix the Gradle semantic-release plugin.
// Remove this if you forked it to support building only.

View File

@@ -1,2 +1,2 @@
kotlin.code.style = official
version = 2.11.0
version = 2.12.1

View File

@@ -1,4 +1,4 @@
package app.revanced.patches.meta
package app.revanced.patches.meta.readme
import java.io.File
import kotlin.io.writeText
@@ -8,36 +8,16 @@ import app.revanced.patcher.extensions.PatchExtensions.compatiblePackages
import app.revanced.patcher.extensions.PatchExtensions.patchName
import app.revanced.patcher.extensions.PatchExtensions.description
class ReadmeGenerator {
class Generator {
companion object {
@JvmStatic
fun main(args: Array<String>) {
//should be moved to a file?
val generalReadme =
"""
# ReVanced Patches
🧩 Official patches by ReVanced
# Patch list
""".trimIndent()
val tableHeader =
"""
| 💊 Patch | 📜 Description | 🎯 Target Package | 🏹 Target Version |
|:-----:|:-----------:|:--------------:|:----------------------:|
""".trimIndent()
val readmeFile = File("README.md")
val buildDir = File("build/libs/")
val buildJar = buildDir.listFiles().first { it.name.startsWith("revanced-patches-") && it.name.endsWith(".jar") }
val bundle = JarPatchBundle(buildJar.absolutePath).loadPatches()
val builder = StringBuilder()
builder.appendLine(generalReadme)
builder.appendLine(tableHeader)
val table = StringBuilder()
for (patch in bundle) {
val humanName =
@@ -46,10 +26,16 @@ class ReadmeGenerator {
val compatiblePackage = patch.compatiblePackages?.first()
val latestVersion = compatiblePackage?.versions?.maxByOrNull { it.replace(".", "").toInt() } ?: "all"
builder.appendLine("|$humanName|${patch.description}|`${compatiblePackage?.name}`|$latestVersion|")
table.appendLine("|$humanName|${patch.description}|`${compatiblePackage?.name}`|$latestVersion|")
}
readmeFile.writeText(builder.toString())
val readMeTemplateFile = File("README-template.md")
val readMeTemplate = Template(readMeTemplateFile.readText())
readMeTemplate.replaceVariable("table", table.toString())
val readMeFile = File("README.md")
readMeFile.writeText(readMeTemplate.toString())
}
}
}

View File

@@ -0,0 +1,14 @@
package app.revanced.patches.meta.readme
class Template(val template: String) {
val result: StringBuilder = StringBuilder(template)
fun replaceVariable(name: String, value: String) {
val regex = Regex("\\{\\{\\s?$name\\s?\\}\\}")
val range = regex.find(result)!!.range
result.replace(range.start, range.endInclusive + 1, value)
}
override fun toString(): String = result.toString()
}

View File

@@ -14,7 +14,7 @@ import app.revanced.patches.music.premium.backgroundplay.fingerprints.Background
@Patch
@Name("background-play")
@Description("Enable playing music in the background.")
@Description("Enables playing music in the background.")
@BackgroundPlayCompatibility
@Version("0.0.1")
class BackgroundPlayPatch : BytecodePatch(

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34","17.24.35","17.25.34")
"com.google.android.youtube", arrayOf("17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.25.34")
"com.google.android.youtube", arrayOf("17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34","17.24.35","17.25.34")
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.24.34", "17.25.34")
"com.google.android.youtube", arrayOf("17.24.34", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34","17.24.35","17.25.34")
"com.google.android.youtube", arrayOf("17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34","17.24.35","17.25.34")
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.25.34")
"com.google.android.youtube", arrayOf("17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.24.35", "17.25.34")
"com.google.android.youtube", arrayOf("17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -21,7 +21,7 @@ import kotlin.io.path.exists
dependencies = [FixLocaleConfigErrorPatch::class]
)
@Name("premium-heading")
@Description("Show the premium branding on the the YouTube home screen.")
@Description("Shows premium branding on the YouTube home screen.")
@PremiumHeadingCompatibility
@Version("0.0.1")
class PremiumHeadingPatch : ResourcePatch() {

View File

@@ -19,7 +19,7 @@ import java.nio.file.Files
dependencies = [FixLocaleConfigErrorPatch::class]
)
@Name("custom-branding")
@Description("Change the branding of YouTube.")
@Description("Changes the branding of YouTube.")
@CustomBrandingCompatibility
@Version("0.0.1")
class CustomBrandingPatch : ResourcePatch() {

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34","17.24.35","17.25.34")
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.23.35", "17.23.36", "17.24.34","17.24.35","17.25.34")
"com.google.android.youtube", arrayOf("17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34","17.24.35","17.25.34")
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34","17.24.35","17.25.34")
"com.google.android.youtube", arrayOf("17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.23.35", "17.23.36", "17.24.34","17.24.35","17.25.34")
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34","17.24.35","17.25.34")
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.24.34", "17.24.35", "17.25.34")
"com.google.android.youtube", arrayOf("17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.25.34")
"com.google.android.youtube", arrayOf("17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.24.34","17.25.34")
"com.google.android.youtube", arrayOf("17.24.34", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.24.34", "17.24.35", "17.25.34")
"com.google.android.youtube", arrayOf("17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.03.38", "17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34","17.24.35","17.25.34")
"com.google.android.youtube", arrayOf("17.03.38", "17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34","17.24.35","17.25.34")
"com.google.android.youtube", arrayOf("17.14.35", "17.17.34", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)

View File

@@ -5,7 +5,7 @@ import app.revanced.patcher.annotation.Package
@Compatibility(
[Package(
"com.google.android.youtube", arrayOf("17.14.35", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34","17.24.35","17.25.34")
"com.google.android.youtube", arrayOf("17.14.35", "17.19.36", "17.20.37", "17.22.36", "17.23.35", "17.23.36", "17.24.34", "17.24.35", "17.25.34", "17.26.35")
)]
)
@Target(AnnotationTarget.CLASS)