mirror of
https://github.com/LingandRX/script_library.git
synced 2025-10-28 08:41:16 +08:00
change:添加备注
This commit is contained in:
parent
e7b26f7e04
commit
4d49757cee
5
.gitignore
vendored
5
.gitignore
vendored
@ -1,2 +1,5 @@
|
|||||||
.venv
|
.venv
|
||||||
.idea
|
.idea
|
||||||
|
/build/
|
||||||
|
/dist/
|
||||||
|
/ncmTranslator.spec
|
||||||
|
|||||||
@ -119,9 +119,6 @@ if __name__ == '__main__':
|
|||||||
rootdir = fspath(Path(__file__).parent.resolve())
|
rootdir = fspath(Path(__file__).parent.resolve())
|
||||||
print('当前需要处理的文件夹路径: ' + rootdir)
|
print('当前需要处理的文件夹路径: ' + rootdir)
|
||||||
|
|
||||||
start_time = time.time()
|
|
||||||
print('开始处理 ' + time.strftime("%Y-%m-%d %H:%M:%S", time.localtime()))
|
|
||||||
|
|
||||||
file_list = os.listdir(rootdir)
|
file_list = os.listdir(rootdir)
|
||||||
tasks = []
|
tasks = []
|
||||||
for file in file_list:
|
for file in file_list:
|
||||||
@ -137,13 +134,7 @@ if __name__ == '__main__':
|
|||||||
for future in as_completed(futures):
|
for future in as_completed(futures):
|
||||||
try:
|
try:
|
||||||
result_path = future.result()
|
result_path = future.result()
|
||||||
# ✅ 在进度条上方显示文件名称
|
|
||||||
tqdm.write(f"转码完成: {result_path}")
|
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
logging.exception("转码任务出错", exc_info=e)
|
logging.exception("转码任务出错", exc_info=e)
|
||||||
finally:
|
finally:
|
||||||
pbar.update(1)
|
pbar.update(1)
|
||||||
|
|
||||||
end_time = time.time()
|
|
||||||
print('全部文件处理完成 ' + time.strftime("%Y-%m-%d %H:%M:%S", time.localtime()))
|
|
||||||
print('处理时间:', end_time - start_time)
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user