Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Main beta #727

Merged
merged 2 commits into from
Oct 4, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions Honkai_Star_Rail.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def __init__(self) -> None:
'skip_verify': False,
'type': "map",
'version': "map",
'url_zip': f"https://raw.githubusercontent.com/Starry-Wind/StarRailAssistant/map/map.zip",
'url_zip': f"https://raw.githubusercontent.com/Night-stars-1/Auto_Star_Rail_MAP/main/map.zip",
'unzip_path': "map",
'keep_folder': [],
'keep_file': [],
Expand All @@ -75,7 +75,7 @@ def __init__(self) -> None:
'skip_verify': False,
'type': "picture",
'version': "map",
'url_zip': f"https://raw.githubusercontent.com/Starry-Wind/StarRailAssistant/map/picture.zip",
'url_zip': f"https://raw.githubusercontent.com/Night-stars-1/Auto_Star_Rail_MAP/main/picture.zip",
'unzip_path': "picture",
'keep_folder': [],
'keep_file': [],
Expand Down Expand Up @@ -244,10 +244,6 @@ def set_config(self, start = True):
url_ms = [i.replace(" "," "*(len(max(url_ms, key=len))-len(i))) if len(i) < len(max(url_ms, key=len)) else i for i in url_ms]
option = options[url_ms.index(questionary.select(title, url_ms).ask())]
sra_config_obj.apigithub_proxy = option
title = _("请选择你的仓库来源:")
options = ["Starry-Wind", "Night-stars-1"]
option = questionary.select(title, options).ask()
sra_config_obj.github_source = option
while True:
if sra_config_obj.picture_version == "0" or sra_config_obj.map_version == "0":
sra.up_data()
Expand Down
2 changes: 0 additions & 2 deletions utils/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -290,8 +290,6 @@ class SRAData(metaclass=SRADataMeta):
"""切换队伍的队伍编号"""
stop: bool = False
"""是否停止"""
github_source: str = "Night-stars-1"
"""github仓库源"""

def __init__(self) -> None:
...
Expand Down
2 changes: 0 additions & 2 deletions utils/update_file.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ def __init__(self, page: ft.Page=None, pb: ft.ProgressBar=None) -> None:
"""
self.page = page
self.pb = pb
self.github_source = sra_config_obj.github_source

async def verify_file_hash(self, json_path: Path, keep_file: Optional[List[str]] = []) -> bool:
"""
Expand Down Expand Up @@ -180,7 +179,6 @@ async def is_sra_latest(self, type: str, version: str, is_log: bool = True):
try:
api_proxy = sra_config_obj.apigithub_proxy
up_url = f"{api_proxy}https://api.github.com/repos/Starry-Wind/StarRailAssistant/releases/latest" if "http" in api_proxy else f"https://api.github.com/repos/Starry-Wind/StarRailAssistant/releases/latest"
log.info(up_url)
up_reponse = await get(up_url, timeout=2)
up_data = up_reponse.json()
version: str = up_data.get("tag_name")
Expand Down