mirror of
https://github.com/pyenv/pyenv.git
synced 2026-01-31 00:07:33 +09:00
(refactor)
This commit is contained in:
parent
99faf7f217
commit
ff94d498db
@ -124,7 +124,9 @@ def add_version(release, distributions):
|
||||
else:
|
||||
logger.info('Did not find specs for %(distribution)s', locals())
|
||||
|
||||
for release in requests.get(f'https://api.github.com/repos/{MINIFORGE_REPO}/releases').json():
|
||||
|
||||
def main():
|
||||
for release in requests.get(f'https://api.github.com/repos/{MINIFORGE_REPO}/releases').json():
|
||||
version = release['tag_name']
|
||||
|
||||
if version in SKIPPED_RELEASES:
|
||||
@ -133,7 +135,7 @@ for release in requests.get(f'https://api.github.com/repos/{MINIFORGE_REPO}/rele
|
||||
logger.info('Looking for %(version)s in %(out_dir)s', locals())
|
||||
|
||||
# mambaforge is retired https://github.com/conda-forge/miniforge/releases/tag/24.11.2-0
|
||||
if version_tuple(version) >= (24,11,2):
|
||||
if version_tuple(version) >= (24, 11, 2):
|
||||
distributions = DISTRIBUTIONS
|
||||
else:
|
||||
distributions = DISTRIBUTIONS_PRE25
|
||||
@ -141,3 +143,6 @@ for release in requests.get(f'https://api.github.com/repos/{MINIFORGE_REPO}/rele
|
||||
if any(not list(out_dir.glob(f'{distribution}*-{version}')) for distribution in distributions):
|
||||
logger.info('Downloading %(version)s', locals())
|
||||
add_version(release, distributions)
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user