Commit cba58671 by sikang

update script

parent 4f5bf85e
...@@ -384,13 +384,17 @@ class Function: ...@@ -384,13 +384,17 @@ class Function:
#copy logo #copy logo
def find_logo(self,config): def find_logo(self,config):
path = "/Users/connor/Downloads/%s"%config['corp_id'] path = "/Users/connor/Downloads/%s"%config['corp_id']
file = {} targets = {}
for root, dirs, files in os.walk(path): for root, dirs, files in os.walk(path):
for file in files: for file in files:
if "logo_512" in file and "logo" not in file.keys(): if "logo_512" in file and "logo" not in targets.keys():
file['logo'] = file targets['logo'] = os.path.join(root,file)
if "1024_500" in file and "top" not in file.keys(): if "1024_500" in file and "top" not in targets.keys():
file['top'] = file targets['top'] = os.path.join(root,file)
img_path = "%s/app/src/main/res/drawable-xxhdpi"%config['root']
shutil.copy(targets['logo'], "%s/logo_majia.png" % img_path)
shutil.copy(targets['top'], "%s/top.png" % img_path)
print(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