代码拉取完成,页面将自动刷新
import json
import os
import platform
def load_config(config_path):
"""
loading config
"""
try:
with open(config_path, "r", encoding="utf-8") as f:
return json.load(f)
except Exception as e:
print("Config file not found, {}".format(e))
raise
folder_name = 'ClematisLogSCC'
# Get the operating system type
system_type = platform.system()
# Set the desktop path according to the operating system type
if system_type == "Windows":
desktop_path = os.path.dirname(os.getcwd())
else:
desktop_path = os.path.join(os.path.expanduser("~"), "Desktop") # Default case
project_folder_path = os.path.join(desktop_path, folder_name)
config_path = os.path.join(project_folder_path, 'config.json')
CONFIG = load_config(config_path)
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。