style: update

This commit is contained in:
wcbing 2025-11-05 11:08:32 +08:00
parent be7d68e1b7
commit 79ce0dc076
3 changed files with 5 additions and 5 deletions

View File

@ -48,8 +48,7 @@
### Github Releses ### Github Releses
> 因服务器资源有限,本仓库可能无法收录部分大文件。 > 也可投稿至星火商店的 [Github Releases 更新配置仓库](https://gitee.com/spark-building-service/github),其和本部分内容是同源的。
> 有收录需求也可投稿至星火商店的 [Github Releases 更新配置仓库](https://gitee.com/spark-building-service/github),其和本部分内容是同源的。
| 软件名 | 包名 | amd64 | arm64 | | 软件名 | 包名 | amd64 | arm64 |
| ----- | ---- | ----- | ----- | | ----- | ---- | ----- | ----- |

View File

@ -74,6 +74,7 @@ def check_download(name: str, version: str, url: str, arch: str) -> None:
os.makedirs(os.path.join(DEB_BASE_DIR, arch), exist_ok=True) os.makedirs(os.path.join(DEB_BASE_DIR, arch), exist_ok=True)
if not download(url, file_path): if not download(url, file_path):
return return
logging.info(f"Downloaded {name}:{arch} ({version})")
os.makedirs(os.path.join(PACKAGES_DIR, arch), exist_ok=True) os.makedirs(os.path.join(PACKAGES_DIR, arch), exist_ok=True)
if not scan(name, arch, url, file_path): if not scan(name, arch, url, file_path):
return return

View File

@ -7,7 +7,7 @@ import re
from concurrent.futures import ThreadPoolExecutor, wait from concurrent.futures import ThreadPoolExecutor, wait
from check_downloader import check_download from check_downloader import check_download
github_info_list = {} git_repo_list = {}
CONFIG = {"data_dir": "data", "proxy": "", "thread": 5} CONFIG = {"data_dir": "data", "proxy": "", "thread": 5}
@ -31,11 +31,11 @@ if __name__ == "__main__":
# read all repo info 读取所有仓库配置 # read all repo info 读取所有仓库配置
with open(os.path.join(CONFIG["data_dir"], "github.json"), "r") as f: with open(os.path.join(CONFIG["data_dir"], "github.json"), "r") as f:
github_info_list = json.load(f) git_repo_list = json.load(f)
tasks = [] tasks = []
with ThreadPoolExecutor(max_workers=CONFIG["thread"]) as executor: with ThreadPoolExecutor(max_workers=CONFIG["thread"]) as executor:
for name, repo in github_info_list.items(): for name, repo in git_repo_list.items():
if "site" in repo: if "site" in repo:
repo_url = os.path.join(repo["site"], repo['repo']) repo_url = os.path.join(repo["site"], repo['repo'])
else: else: