nikhilbadyal / docker-py-revanced

One Click Python util to build all Revanced apps.
https://nikhilbadyal.github.io/docker-py-revanced/
GNU General Public License v3.0
549 stars 426 forks source link

Multi Patching from different sources #550

Open sawankumarbundelkhandi opened 4 weeks ago

sawankumarbundelkhandi commented 4 weeks ago

Support guidelines

Description

It would be useful to allow multi patching - using the patched output apk as input to patches from other creators.

Motivation

If I need to patch Spotify, I would first utilize the "Change Package Name" patch from the ReVanced project, given that Spotify is pre-installed on my device. This patch can be found on the ReVanced GitHub repository here. After adjusting the package name, I would proceed with applying the necessary Spotify-specific patches from the Dropped Patches repository, which are available here

I can use the same for picking from patches from Revanced and then some from Revanced Extended for youtube.

Additional Context

Rename package patch - https://github.com/ReVanced/revanced-patches/ Spotify premium patch - https://github.com/indrastorms/Dropped-Patches/

sawankumarbundelkhandi commented 4 weeks ago

@nikhilbadyal just found this - https://github.com/indrastorms/Dropped-Patches/issues/62

Maybe we can use - bundle with cli using -b revanced.jar -b dropped-patches.jar. Does docker-py-revanced support passing multiples bundle?

IMXEren commented 4 weeks ago

Not currently and choosing an appropriate seperator is another question.

I think it'd good to use variables in env. For example:

S1JAR=https://github.com/ReVanced/revanced-patches
S2JAR=https://github.com/indrastorm/Dropped-patches
SPOTIFY_PATCHES_DL=@S1JAR,@S2JAR  ## or $ instead of @

I think this would be better than inline. Undefined variables should raise an error.

nikhilbadyal commented 3 weeks ago

As stated by @IMXEren , currently builder doesn't support multiple bundles. Unfortunately I'm busy for a while so might not be able to implement it as well. Will appreciate if you/anyone can raise a PR. I'll be happy to review it.