Update compileall.py

This commit is contained in:
blueloveTH 2026-01-06 15:15:50 +08:00
parent 3e182d5c6b
commit f3bf7c6321

View File

@ -12,8 +12,9 @@ output_dir = sys.argv[3]
def do_compile(src_path, dst_path): def do_compile(src_path, dst_path):
assert os.path.isfile(src_path) assert os.path.isfile(src_path)
cmd = f'{pkpy_exe} --compile "{src_path}" "{dst_path}"' cmd = f'{pkpy_exe} --compile "{src_path}" "{dst_path}"'
print(src_path) if os.system(cmd) != 0:
assert os.system(cmd) == 0 print(src_path)
exit(1)
if os.path.isfile(source_dir): if os.path.isfile(source_dir):
if output_dir.endswith('.py'): if output_dir.endswith('.py'):