mirror of
https://github.com/sotam0316/docker-py-revanced.git
synced 2026-04-25 03:48:37 +09:00
🐛 Updated for revanced cli v5
This commit is contained in:
committed by
Nikhil Badyal
parent
3e3d14c14a
commit
614046a15a
+4
-6
@@ -32,8 +32,7 @@ class APP(object):
|
||||
self.experiment = False
|
||||
self.cli_dl = config.env.str(f"{app_name}_CLI_DL".upper(), config.global_cli_dl)
|
||||
self.patches_dl = config.env.str(f"{app_name}_PATCHES_DL".upper(), config.global_patches_dl)
|
||||
self.integrations_dl = config.env.str(f"{app_name}_INTEGRATIONS_DL".upper(), config.global_integrations_dl)
|
||||
self.patches_json_dl = config.env.str(f"{app_name}_PATCHES_JSON_DL".upper(), self.patches_dl)
|
||||
self.patches_json_dl = config.env.str(f"{app_name}_PATCHES_JSON_DL".upper(), config.global_patches_json_dl)
|
||||
self.exclude_request: list[str] = config.env.list(f"{app_name}_EXCLUDE_PATCH".upper(), [])
|
||||
self.include_request: list[str] = config.env.list(f"{app_name}_INCLUDE_PATCH".upper(), [])
|
||||
self.resource: dict[str, dict[str, str]] = {}
|
||||
@@ -149,13 +148,12 @@ class APP(object):
|
||||
# Create a list of resource download tasks
|
||||
download_tasks = [
|
||||
("cli", self.cli_dl, config, ".*jar"),
|
||||
("integrations", self.integrations_dl, config, ".*apk"),
|
||||
("patches", self.patches_dl, config, ".*jar"),
|
||||
("patches_json", self.patches_json_dl, config, ".*json"),
|
||||
("patches", self.patches_dl, config, ".*rvp"),
|
||||
("patches_json", self.patches_json_dl, config, ".*"),
|
||||
]
|
||||
|
||||
# Using a ThreadPoolExecutor for parallelism
|
||||
with ThreadPoolExecutor(4) as executor:
|
||||
with ThreadPoolExecutor(1) as executor:
|
||||
futures = {resource_name: executor.submit(self.download, *args) for resource_name, *args in download_tasks}
|
||||
|
||||
# Wait for all tasks to complete
|
||||
|
||||
Reference in New Issue
Block a user