diff --git a/docs/1_usage.md b/docs/1_usage.md index bf07f49..a3226de 100644 --- a/docs/1_usage.md +++ b/docs/1_usage.md @@ -35,7 +35,7 @@ Learn how to ReVanced CLI. ```bash java -jar revanced-cli.jar -b revanced-patches.jar \ - -l + -l # Names of all patches will be in kebab-case ``` - ### 💉 Use ReVanced CLI to patch an APK file but deploy without root permissions diff --git a/src/main/kotlin/app/revanced/cli/command/MainCommand.kt b/src/main/kotlin/app/revanced/cli/command/MainCommand.kt index 0d3b954..98b4302 100644 --- a/src/main/kotlin/app/revanced/cli/command/MainCommand.kt +++ b/src/main/kotlin/app/revanced/cli/command/MainCommand.kt @@ -241,7 +241,7 @@ internal object MainCommand : Runnable { } // Add patch name - val patchName = patch.patchName.padStart(25) + val patchName = patch.patchName.lowercase().replace("-", " ").padStart(25) append(patchName) // Add description if flag is set. diff --git a/src/main/kotlin/app/revanced/utils/patcher/Patcher.kt b/src/main/kotlin/app/revanced/utils/patcher/Patcher.kt index adbfde5..53eb07e 100644 --- a/src/main/kotlin/app/revanced/utils/patcher/Patcher.kt +++ b/src/main/kotlin/app/revanced/utils/patcher/Patcher.kt @@ -1,6 +1,5 @@ package app.revanced.utils.patcher -import app.revanced.cli.command.MainCommand import app.revanced.cli.command.MainCommand.args import app.revanced.cli.command.MainCommand.logger import app.revanced.cli.command.PatchList @@ -18,8 +17,8 @@ fun Patcher.addPatchesFiltered(allPatches: PatchList) { val includedPatches = mutableListOf>>() allPatches.forEach patchLoop@{ patch -> val compatiblePackages = patch.compatiblePackages - val patchName = patch.patchName - val args = MainCommand.args.patchArgs?.patchingArgs!! + val patchName = patch.patchName.lowercase().replace(" ", "-") + val args = args.patchArgs?.patchingArgs!! val prefix = "Skipping $patchName"