mirror of
https://github.com/revanced/revanced-cli.git
synced 2024-11-11 22:29:24 +01:00
chore: merge branch dev
to main
(#178)
This commit is contained in:
commit
ff0d3dd224
@ -1,3 +1,10 @@
|
|||||||
|
## [2.18.1-dev.1](https://github.com/revanced/revanced-cli/compare/v2.18.0...v2.18.1-dev.1) (2022-12-15)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* don't log when package is incompatible and `exclusive` option is used ([ad81a1b](https://github.com/revanced/revanced-cli/commit/ad81a1b656586226f8b7b8d1123c52b0f3f2e6f7))
|
||||||
|
|
||||||
# [2.18.0](https://github.com/revanced/revanced-cli/compare/v2.17.0...v2.18.0) (2022-12-15)
|
# [2.18.0](https://github.com/revanced/revanced-cli/compare/v2.17.0...v2.18.0) (2022-12-15)
|
||||||
|
|
||||||
|
|
||||||
|
@ -43,6 +43,7 @@ tasks {
|
|||||||
}
|
}
|
||||||
minimize {
|
minimize {
|
||||||
exclude(dependency("org.jetbrains.kotlin:.*"))
|
exclude(dependency("org.jetbrains.kotlin:.*"))
|
||||||
|
exclude(dependency("org.bouncycastle:.*"))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Dummy task to fix the Gradle semantic-release plugin.
|
// Dummy task to fix the Gradle semantic-release plugin.
|
||||||
|
@ -1,2 +1,2 @@
|
|||||||
kotlin.code.style = official
|
kotlin.code.style = official
|
||||||
version = 2.18.0
|
version = 2.18.1-dev.1
|
||||||
|
@ -87,7 +87,7 @@ internal object MainCommand : Runnable {
|
|||||||
names = ["--exclusive"],
|
names = ["--exclusive"],
|
||||||
description = ["Only installs the patches you include, not including any patch by default"]
|
description = ["Only installs the patches you include, not including any patch by default"]
|
||||||
)
|
)
|
||||||
var defaultExclude = false
|
var exclusive = false
|
||||||
|
|
||||||
@Option(names = ["-i", "--include"], description = ["Include patches"])
|
@Option(names = ["-i", "--include"], description = ["Include patches"])
|
||||||
var includedPatches = arrayOf<String>()
|
var includedPatches = arrayOf<String>()
|
||||||
|
@ -18,18 +18,9 @@ fun Patcher.addPatchesFiltered(allPatches: List<Class<out Patch<Context>>>) {
|
|||||||
allPatches.forEach patchLoop@{ patch ->
|
allPatches.forEach patchLoop@{ patch ->
|
||||||
val compatiblePackages = patch.compatiblePackages
|
val compatiblePackages = patch.compatiblePackages
|
||||||
val patchName = patch.patchName
|
val patchName = patch.patchName
|
||||||
|
|
||||||
val prefix = "Skipping $patchName"
|
|
||||||
|
|
||||||
val args = MainCommand.args.patchArgs?.patchingArgs!!
|
val args = MainCommand.args.patchArgs?.patchingArgs!!
|
||||||
|
|
||||||
if (args.excludedPatches.contains(patchName)) {
|
val prefix = "Skipping $patchName"
|
||||||
logger.info("$prefix: Manually excluded")
|
|
||||||
return@patchLoop
|
|
||||||
} else if ((!patch.include || args.defaultExclude) && !args.includedPatches.contains(patchName)) {
|
|
||||||
logger.info("$prefix: Excluded by default")
|
|
||||||
return@patchLoop
|
|
||||||
}
|
|
||||||
|
|
||||||
if (compatiblePackages == null) logger.trace("$patchName: No constraint on packages.")
|
if (compatiblePackages == null) logger.trace("$patchName: No constraint on packages.")
|
||||||
else {
|
else {
|
||||||
@ -51,6 +42,14 @@ fun Patcher.addPatchesFiltered(allPatches: List<Class<out Patch<Context>>>) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (args.excludedPatches.contains(patchName)) {
|
||||||
|
logger.info("$prefix: Manually excluded")
|
||||||
|
return@patchLoop
|
||||||
|
} else if ((!patch.include || args.exclusive) && !args.includedPatches.contains(patchName)) {
|
||||||
|
logger.info("$prefix: Excluded by default")
|
||||||
|
return@patchLoop
|
||||||
|
}
|
||||||
|
|
||||||
logger.trace("Adding $patchName")
|
logger.trace("Adding $patchName")
|
||||||
includedPatches.add(patch)
|
includedPatches.add(patch)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user