feat: 更新项目服务、工具函数和模板

This commit is contained in:
2026-06-25 12:11:16 +08:00
parent 0c54af8d26
commit a155e8fcd9
13 changed files with 446601 additions and 100 deletions

View File

@@ -50,9 +50,11 @@ def load_projects_full():
def save_projects(projects):
"""保存项目配置"""
"""保存项目配置(保留 server 和 external_services"""
full_data = load_projects_full()
full_data['projects'] = projects
with open(PROJECTS_FILE, 'w', encoding='utf-8') as f:
json.dump({'projects': projects}, f, ensure_ascii=False, indent=2)
json.dump(full_data, f, ensure_ascii=False, indent=2)
def check_port(port):