Stop fetching emscripten and binaryen tags the old way (#262)
We now have versioning directly here in this repo for emscripten-releases. This PR makes us stop looking for tags the old way, which looked on github for tags. Rename the files legacy-*.
This commit is contained in:
Родитель
188c3edb9b
Коммит
a382d620e5
52
emsdk
52
emsdk
|
@ -1744,44 +1744,6 @@ def fetch_emscripten_tags():
|
|||
git = GIT(must_succeed=False)
|
||||
|
||||
if git:
|
||||
print('Fetching all tags from Emscripten Github repository...')
|
||||
tags = run_get_output([git, 'ls-remote', '--tags', emscripten_git_repo])
|
||||
if tags[0] != 0: return False # failed to get tags?
|
||||
tags = tags[1]
|
||||
all_tags = []
|
||||
for t in tags.split('\n'):
|
||||
try:
|
||||
t = t[t.index('refs/tags/') + len('refs/tags/'):].strip()
|
||||
if version_key(t) >= version_key('1.28.2'):
|
||||
all_tags += [t]
|
||||
except:
|
||||
pass
|
||||
all_tags = sorted(all_tags, key=version_key)
|
||||
open(sdk_path('emscripten-tags.txt'), 'w').write('\n'.join(all_tags))
|
||||
if len(all_tags) > 0:
|
||||
print('Done. ' + str(len(all_tags)) + ' tagged releases available, latest is ' + all_tags[-1] + '.')
|
||||
else:
|
||||
print('Done. No tagged releases available.')
|
||||
|
||||
print('Fetching all tags from Binaryen Github repository...')
|
||||
tags = run_get_output([git, 'ls-remote', '--tags', binaryen_git_repo])
|
||||
if tags[0] != 0: return False # failed to get tags?
|
||||
tags = tags[1]
|
||||
binaryen_tags = []
|
||||
for t in tags.split('\n'):
|
||||
try:
|
||||
t = t[t.index('refs/tags/') + len('refs/tags/'):].strip()
|
||||
if '.' in t:
|
||||
binaryen_tags += [t]
|
||||
except:
|
||||
pass
|
||||
binaryen_tags = sorted(binaryen_tags, key=version_key)
|
||||
open(sdk_path('binaryen-tags.txt'), 'w').write('\n'.join(binaryen_tags))
|
||||
if len(binaryen_tags) > 0:
|
||||
print('Done. ' + str(len(binaryen_tags)) + ' tagged Binaryen releases available, latest is ' + binaryen_tags[-1] + '.')
|
||||
else:
|
||||
print('Done. No tagged Binaryen releases available.')
|
||||
|
||||
print('Fetching emscripten-releases repository...')
|
||||
emscripten_releases_tot = get_emscripten_releases_tot()
|
||||
if emscripten_releases_tot:
|
||||
|
@ -1833,17 +1795,17 @@ def update_emsdk():
|
|||
fetch_emscripten_tags()
|
||||
|
||||
|
||||
# Lists all tagged versions directly in the Git repositories. These we can pull and compile from source.
|
||||
def load_emscripten_tags():
|
||||
# Lists all legacy (pre-emscripten-releases) tagged versions directly in the Git repositories. These we can pull and compile from source.
|
||||
def load_legacy_emscripten_tags():
|
||||
try:
|
||||
return open(sdk_path('emscripten-tags.txt'), 'r').read().split('\n')
|
||||
return open(sdk_path('legacy-emscripten-tags.txt'), 'r').read().split('\n')
|
||||
except:
|
||||
return []
|
||||
|
||||
|
||||
def load_binaryen_tags():
|
||||
def load_legacy_binaryen_tags():
|
||||
try:
|
||||
return open(sdk_path('binaryen-tags.txt'), 'r').read().split('\n')
|
||||
return open(sdk_path('legacy-binaryen-tags.txt'), 'r').read().split('\n')
|
||||
except:
|
||||
return []
|
||||
|
||||
|
@ -1931,11 +1893,11 @@ def load_sdk_manifest():
|
|||
print(str(e))
|
||||
return
|
||||
|
||||
emscripten_tags = load_emscripten_tags()
|
||||
emscripten_tags = load_legacy_emscripten_tags()
|
||||
llvm_precompiled_tags_32bit = list(reversed(load_llvm_precompiled_tags_32bit()))
|
||||
llvm_precompiled_tags_64bit = list(reversed(load_llvm_precompiled_tags_64bit()))
|
||||
llvm_precompiled_tags = llvm_precompiled_tags_32bit + llvm_precompiled_tags_64bit
|
||||
binaryen_tags = load_binaryen_tags()
|
||||
binaryen_tags = load_legacy_binaryen_tags()
|
||||
llvm_32bit_nightlies = list(reversed(load_llvm_32bit_nightlies()))
|
||||
llvm_64bit_nightlies = list(reversed(load_llvm_64bit_nightlies()))
|
||||
emscripten_nightlies = list(reversed(load_emscripten_nightlies()))
|
||||
|
|
Загрузка…
Ссылка в новой задаче