Browse Source

download: Update yaml data with new hashes

pull/11891/head
Max Gautier 2 months ago
parent
commit
c94daa4ff5
Failed to extract signature
1 changed files with 19 additions and 0 deletions
  1. 19
      scripts/download_hash.py

19
scripts/download_hash.py

@ -184,6 +184,10 @@ def download_hash(only_downloads: [str]) -> None:
],
strict=True))
components_supported_arch = {
component.removesuffix('_checksums'): [a for a in archs.keys()]
for component, archs in data.items()
}
new_versions = {
c:
{v for v in github_versions[c]
@ -216,6 +220,21 @@ def download_hash(only_downloads: [str]) -> None:
return (hash_file.content.decode().split()[0])
for component, versions in new_versions.items():
c = component + '_checksums'
for arch in components_supported_arch[component]:
for version in versions:
data[c][arch][str(version)] = f"{downloads[component].get('hashtype', 'sha256')}:{get_hash(component, version, arch)}"
data[c] = {arch :
{v :
versions[v] for v in sorted(versions.keys(),
key=Version,
reverse=True)
}
for arch, versions in data[c].items()
}
with open(CHECKSUMS_YML, "w") as checksums_yml:
yaml.dump(data, checksums_yml)

Loading…
Cancel
Save