mirror of
https://github.com/commaai/agnos-builder.git
synced 2026-10-01 03:43:49 +08:00
flash_all.sh: download from firmware.json
This commit is contained in:
@@ -46,6 +46,9 @@ def download_and_decompress(url, expected_hash, filename):
|
||||
assert(sha256.hexdigest().lower() == expected_hash.lower())
|
||||
|
||||
def load_manifest(url):
|
||||
if Path(url).is_file():
|
||||
with open(url) as f:
|
||||
return json.loads(f.read())
|
||||
r = requests.get(url)
|
||||
r.raise_for_status()
|
||||
return json.loads(r.content.decode())
|
||||
|
||||
Reference in New Issue
Block a user