mirror of
https://github.com/MarioSpore/Grinch-AP.git
synced 2025-10-20 20:01:31 -06:00
setup: Downgrade bundled SNI to 0.0.100 (#5228)
This commit is contained in:
7
setup.py
7
setup.py
@@ -16,6 +16,10 @@ from collections.abc import Iterable, Sequence
|
|||||||
from hashlib import sha3_512
|
from hashlib import sha3_512
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
|
|
||||||
|
|
||||||
|
SNI_VERSION = "v0.0.100" # change back to "latest" once tray icon issues are fixed
|
||||||
|
|
||||||
|
|
||||||
# This is a bit jank. We need cx-Freeze to be able to run anything from this script, so install it
|
# This is a bit jank. We need cx-Freeze to be able to run anything from this script, so install it
|
||||||
requirement = 'cx-Freeze==8.0.0'
|
requirement = 'cx-Freeze==8.0.0'
|
||||||
try:
|
try:
|
||||||
@@ -89,7 +93,8 @@ def download_SNI() -> None:
|
|||||||
machine_name = platform.machine().lower()
|
machine_name = platform.machine().lower()
|
||||||
# force amd64 on macos until we have universal2 sni, otherwise resolve to GOARCH
|
# force amd64 on macos until we have universal2 sni, otherwise resolve to GOARCH
|
||||||
machine_name = "universal" if platform_name == "darwin" else machine_to_go.get(machine_name, machine_name)
|
machine_name = "universal" if platform_name == "darwin" else machine_to_go.get(machine_name, machine_name)
|
||||||
with urllib.request.urlopen("https://api.github.com/repos/alttpo/sni/releases/latest") as request:
|
sni_version_ref = "latest" if SNI_VERSION == "latest" else f"tags/{SNI_VERSION}"
|
||||||
|
with urllib.request.urlopen(f"https://api.github.com/repos/alttpo/SNI/releases/{sni_version_ref}") as request:
|
||||||
data = json.load(request)
|
data = json.load(request)
|
||||||
files = data["assets"]
|
files = data["assets"]
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user