2023-04-09 18:49:39 +08:00
|
|
|
#!/usr/bin/env python3
|
|
|
|
# 更新构建时间
|
|
|
|
import os
|
|
|
|
import json
|
|
|
|
import platform
|
|
|
|
import datetime
|
|
|
|
programPath = os.path.split(os.path.realpath(__file__))[0] # 返回 string
|
2023-09-30 10:17:59 +08:00
|
|
|
with open(f"{programPath}/deb/opt/apps/deepin-wine-runner/information.json", "r") as file:
|
2023-04-09 18:49:39 +08:00
|
|
|
info = json.loads(file.read())
|
|
|
|
info["Time"] = datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S") + " " + platform.platform()
|
2023-09-30 10:17:59 +08:00
|
|
|
with open(f"{programPath}/deb/opt/apps/deepin-wine-runner/information.json", "w") as file:
|
2023-04-09 18:49:39 +08:00
|
|
|
file.write(json.dumps(info, ensure_ascii=False, indent=4))
|