Commit 3bc70832 by sikang

bug fiz

parent fc4436a6
...@@ -98,6 +98,9 @@ class PackageGarble: ...@@ -98,6 +98,9 @@ class PackageGarble:
os.rename(key, mapping[key]) os.rename(key, mapping[key])
def __process_files(self, path): def __process_files(self, path):
if os.path.isfile(path):
self.__process_file_content(path, path.file_name())
else:
for root, dirs, files in os.walk(path): for root, dirs, files in os.walk(path):
directory = os.path.join(os.getcwd(), root) directory = os.path.join(os.getcwd(), root)
for file in files: for file in files:
...@@ -129,6 +132,9 @@ class PackageGarble: ...@@ -129,6 +132,9 @@ class PackageGarble:
self.pkg_mapping[key] = key self.pkg_mapping[key] = key
#全局替换 #全局替换
self.__process_files("%s/app/proguard-rules.pro" % config['root'])
self.__process_files("%s/lib_base/proguard-rules.pro" % config['root'])
self.__process_files("%s/app/src/main" % config['root']) self.__process_files("%s/app/src/main" % config['root'])
self.__process_files("%s/lib_base/src/main" % config['root']) self.__process_files("%s/lib_base/src/main" % config['root'])
......
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