Commit 290dffe0 by sikang

update

parent 7e178723
......@@ -130,3 +130,26 @@ class PackageGarble:
print("done")
if __name__ == "__main__":
garble = PackageGarble()
#project根目录相对路径
config = {"root" : "../../"}
print("find pkgs...")
#生成混淆字典
garble.__find_pkgs("%s/app/src/main/java" % config['root'])
#重命名路径
garble.__rename_pkg("%s/app/src/main/java" % config['root'])
#忽略3级以下路径(例如com com.common),避免干扰到三方SDK
for (key,value) in garble.pkg_mapping.items():
if len(key.split(".")) < 3:
garble.pkg_mapping[key] = key
#全局替换
garble.__process_files("%s/app/src/main" % config['root'])
print("done")
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment