fix updater
This commit is contained in:
parent
7de5582022
commit
54940b6326
1 changed files with 2 additions and 2 deletions
|
@ -9,7 +9,7 @@ async def git_notifications_update():
|
|||
cwd = os.getcwd()
|
||||
os.chdir(cwd)
|
||||
while True:
|
||||
if termux_api == 0:
|
||||
if termux_api:
|
||||
logger.info('Checking for updates...')
|
||||
fetching_git = os.system('git fetch')
|
||||
if fetching_git == 0:
|
||||
|
@ -20,7 +20,7 @@ async def git_notifications_update():
|
|||
logger.info('updates not found, nothing to do')
|
||||
else:
|
||||
os.system(
|
||||
f"cat upd_info | termux-notification -i ub4tgupd --title 'ub4tg: update avalaible!' --button1 'Get update' --button1-action 'termux-notification-remove ub4tgupd'; cd {cwd}; git pull; termux-toast 'ub4tg updated, now restart it for apply update'")
|
||||
f"cat upd_info | termux-notification -i ub4tgupd --title 'ub4tg: update avalaible!' --button1 'Get update' --button1-action 'termux-notification-remove ub4tgupd; cd {cwd}; git pull; termux-toast 'ub4tg updated, now restart it for apply update''")
|
||||
else:
|
||||
os.system(
|
||||
"termux-toast '[ub4tg]: failed fetching update, maybe connection error, check console log for more info'")
|
||||
|
|
Loading…
Reference in a new issue