diff --git a/src/cmd.py b/src/cmd.py index 9bc75c3..6fa6879 100644 --- a/src/cmd.py +++ b/src/cmd.py @@ -103,19 +103,19 @@ def cli(): def upload_to_cloudflare(args): logger.info("Uploading to Cloudflare") blocklists = utils.utils.get_blocklists(args.blocklists) - blocklists = utils.adblock_zerotrust.apply_whitelists(blocklists, args.whitelists) - lists = utils.adblock_zerotrust.split_list(blocklists) - utils.adblock_zerotrust.upload_to_cloudflare(lists, ACCOUNT_ID, TOKEN) + blocklists = utils.upload.apply_whitelists(blocklists, args.whitelists) + lists = utils.upload.split_list(blocklists) + utils.upload.upload_to_cloudflare(lists, ACCOUNT_ID, TOKEN) cloud_lists = utils.utils.get_lists(ACCOUNT_ID, TOKEN) cloud_lists = utils.utils.filter_adblock_lists(cloud_lists) - utils.adblock_zerotrust.create_dns_policy(cloud_lists, ACCOUNT_ID, TOKEN) + utils.upload.create_dns_policy(cloud_lists, ACCOUNT_ID, TOKEN) def delete_from_cloudflare(args): logger.info("Deleting from Cloudflare") rules = utils.utils.get_gateway_rules(ACCOUNT_ID, TOKEN) - utils.delete_adblock_zerotrust.delete_adblock_policy(rules, ACCOUNT_ID, TOKEN) + utils.delete.delete_adblock_policy(rules, ACCOUNT_ID, TOKEN) lists = utils.utils.get_lists(ACCOUNT_ID, TOKEN) lists = utils.utils.filter_adblock_lists(lists) - utils.delete_adblock_zerotrust.delete_adblock_list(lists, ACCOUNT_ID, TOKEN) + utils.delete.delete_adblock_list(lists, ACCOUNT_ID, TOKEN) if __name__ == "__main__": cli() diff --git a/src/utils/__init__.py b/src/utils/__init__.py index b045e2a..ed1e77e 100644 --- a/src/utils/__init__.py +++ b/src/utils/__init__.py @@ -1,3 +1,3 @@ from .utils import * -from .adblock_zerotrust import * -from .delete_adblock_zerotrust import * +from .upload import * +from .delete import * diff --git a/src/utils/delete_adblock_zerotrust.py b/src/utils/delete.py similarity index 100% rename from src/utils/delete_adblock_zerotrust.py rename to src/utils/delete.py diff --git a/src/utils/adblock_zerotrust.py b/src/utils/upload.py similarity index 100% rename from src/utils/adblock_zerotrust.py rename to src/utils/upload.py