mirror of
https://github.com/ail-project/ail-framework.git
synced 2025-02-07 09:56:24 +00:00
fix: [ail updater] remove update between tags
This commit is contained in:
parent
32e7fb8b55
commit
3194fb0daa
2 changed files with 26 additions and 33 deletions
|
@ -311,31 +311,31 @@ def update_ail(current_tag, list_upper_tags_remote, current_version_path, is_for
|
||||||
print(f'{TERMINAL_RED} Relaunch Launcher {TERMINAL_DEFAULT}')
|
print(f'{TERMINAL_RED} Relaunch Launcher {TERMINAL_DEFAULT}')
|
||||||
sys.exit(3)
|
sys.exit(3)
|
||||||
|
|
||||||
# EMERGENCY UPDATE between two tags
|
# # EMERGENCY UPDATE between two tags
|
||||||
if len(list_upper_tags_remote) == 1:
|
# if len(list_upper_tags_remote) == 1:
|
||||||
# additional update (between 2 commits on the same version)
|
# # additional update (between 2 commits on the same version)
|
||||||
additional_update_path = os.path.join(os.environ['AIL_HOME'], 'update', current_tag, 'additional_update.sh')
|
# additional_update_path = os.path.join(os.environ['AIL_HOME'], 'update', current_tag, 'additional_update.sh')
|
||||||
if os.path.isfile(additional_update_path):
|
# if os.path.isfile(additional_update_path):
|
||||||
print()
|
# print()
|
||||||
print(f'{TERMINAL_YELLOW}------------------------------------------------------------------')
|
# print(f'{TERMINAL_YELLOW}------------------------------------------------------------------')
|
||||||
print('- Launching Additional Update: -')
|
# print('- Launching Additional Update: -')
|
||||||
print(f'-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --{TERMINAL_DEFAULT}')
|
# print(f'-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --{TERMINAL_DEFAULT}')
|
||||||
process = subprocess.run(['bash', additional_update_path],
|
# process = subprocess.run(['bash', additional_update_path],
|
||||||
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
# stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
||||||
if process.returncode == 0:
|
# if process.returncode == 0:
|
||||||
output = process.stdout.decode()
|
# output = process.stdout.decode()
|
||||||
print(output)
|
# print(output)
|
||||||
else:
|
# else:
|
||||||
print(f'{TERMINAL_RED}{process.stderr.decode()}{TERMINAL_DEFAULT}')
|
# print(f'{TERMINAL_RED}{process.stderr.decode()}{TERMINAL_DEFAULT}')
|
||||||
aborting_update()
|
# aborting_update()
|
||||||
sys.exit(1)
|
# sys.exit(1)
|
||||||
|
#
|
||||||
|
# print()
|
||||||
|
# print(f'{TERMINAL_YELLOW}**************** AIL Successfully Updated *****************{TERMINAL_DEFAULT}')
|
||||||
|
# print()
|
||||||
|
# exit(0)
|
||||||
|
|
||||||
print()
|
if list_upper_tags_remote:
|
||||||
print(f'{TERMINAL_YELLOW}**************** AIL Successfully Updated *****************{TERMINAL_DEFAULT}')
|
|
||||||
print()
|
|
||||||
exit(0)
|
|
||||||
|
|
||||||
else:
|
|
||||||
for v_update in list_upper_tags_remote:
|
for v_update in list_upper_tags_remote:
|
||||||
if is_fork:
|
if is_fork:
|
||||||
version_tag = v_update
|
version_tag = v_update
|
||||||
|
@ -459,7 +459,7 @@ if __name__ == "__main__":
|
||||||
print()
|
print()
|
||||||
list_upper_tags_remote = get_git_upper_tags_remote(current_tag.replace('v', ''), is_fork)
|
list_upper_tags_remote = get_git_upper_tags_remote(current_tag.replace('v', ''), is_fork)
|
||||||
# new release
|
# new release
|
||||||
if len(list_upper_tags_remote) > 1:
|
if len(list_upper_tags_remote) > 0:
|
||||||
print('New Releases:')
|
print('New Releases:')
|
||||||
if is_fork:
|
if is_fork:
|
||||||
for upper_tag in list_upper_tags_remote:
|
for upper_tag in list_upper_tags_remote:
|
||||||
|
|
|
@ -17,20 +17,13 @@ echo -e $GREEN"Shutting down AIL ..."$DEFAULT
|
||||||
bash ${AIL_BIN}/LAUNCH.sh -ks
|
bash ${AIL_BIN}/LAUNCH.sh -ks
|
||||||
wait
|
wait
|
||||||
|
|
||||||
echo -e $GREEN"Updating UI resources..."$DEFAULT
|
|
||||||
bash ${AIL_BIN}/LAUNCH.sh -ut
|
|
||||||
wait
|
|
||||||
|
|
||||||
echo -e $GREEN"Updating python requirement..."$DEFAULT
|
|
||||||
pip install -U flask-sock
|
|
||||||
|
|
||||||
# SUBMODULES #
|
# SUBMODULES #
|
||||||
git submodule update
|
git submodule update
|
||||||
|
|
||||||
echo ""
|
echo ""
|
||||||
echo -e $GREEN"Updating AIL VERSION ..."$DEFAULT
|
echo -e $GREEN"Updating AIL VERSION ..."$DEFAULT
|
||||||
echo ""
|
echo ""
|
||||||
python ${AIL_HOME}/update/v6.0/Update.py
|
python ${AIL_HOME}/update/v6.0.1/Update.py
|
||||||
wait
|
wait
|
||||||
echo ""
|
echo ""
|
||||||
echo ""
|
echo ""
|
||||||
|
|
Loading…
Add table
Reference in a new issue