from android_discord_patches import patch_theme import shutil import os def disassemble(): shutil.rmtree("discord", ignore_errors=True) os.system("apktool d ./discord.apk -o discord") def patch(): patch_theme() input("[hit enter]") def reassemble(): os.system("apktool b discord -o discord-patched.apk") os.system( "apksigner sign " "--ks discord.keystore " "--ks-pass file:discord.keystore.pw " "--in discord-patched.apk " "--out discord-patched-signed.apk " ) if __name__ == "__main__": disassemble() patch() reassemble()