revanced-patcher
                                
                                 revanced-patcher copied to clipboard
                                
                                    revanced-patcher copied to clipboard
                            
                            
                            
                        feat: cross-platform patch bundle format
Issue:
Patches can have resources. On Android, this will not be possible.
Solution
Introduce a patch bundle format. Can be a ZIP file with the dex'ed resources for DexPatchBundle and the regular JAR file for JarPatchBundle.
The patcher would either need to introduce an API for patch resources or extract the resources to the patch bundle's specific cache directory to which a resource patch will have access via the data parameter. The implementation of the API on the other hand would require to return a  File for resources from the ZIP file.  Example: data.patchBundleResources[resourcePath]. This way writing to the cache directory would not be necessary anymore.
RE: https://github.com/revanced/revanced-patches/pull/76
Isn't this overcomplicated? Just keep all resources in integrations and just merge all of them into yt?
Not the task of the patcher. What if we do not want sponsorblock strings but only ryd.
Not the task of the patcher. What if we do not want sponsorblock strings but only ryd.
I know that, but who cares about sponsorblockstrings being in the ReVanced APK?
This would overcomplicate things by A lot. If you do it that way, every patch would need its own settings class too for ex.
I know that, but who cares about sponsorblockstrings being in the ReVanced APK?
These strings are for the overlay buttons and other elements. They are mandatory.
This would overcomplicate things by A lot. If you do it that way, every patch would need its own settings class too for ex.
Each patch which needs its own resources such as strings or xmls, has to provide them via a dependant resource patch.
Yes I know that. But wouldn't it be easier to check in integrations if the patch is installed and hide the settings etc if it's not?
If sb patch is excluded, ideally no reference to sb should exist. ReVanced is modular for a reason.