1
0
mirror of https://github.com/0O0o0oOoO00/Alas.git synced 2026-05-14 19:59:25 +08:00

adj: do not generate assets.py when don't have resource

This commit is contained in:
0O0o0oOoO00
2025-09-16 23:18:57 +08:00
parent 87f392cabc
commit eaca620c8b

View File

@@ -218,12 +218,15 @@ class ModuleExtractor(ModuleExtractor):
v.sort()
logger.info('Module: %s(%s)' % (self.name, len(exp)))
exp = IMPORT_EXP + exp
if exp:
exp = IMPORT_EXP + exp
for prefix_name in prefix_assets.keys():
prefix_assets[prefix_name] = IMPORT_EXP + prefix_assets[prefix_name]
return exp, prefix_assets
def write_to_file(self, file, text):
if not text:
return
with open(file, 'w', newline='') as f:
for line in text:
f.write(line + '\n')