Management panel shows update commands streams

This commit is contained in:
Vinicius Moreira
2019-06-18 17:01:13 -03:00
parent 833f7c142e
commit 3ffe2ad96f
9 changed files with 92 additions and 45 deletions

View File

@@ -68,8 +68,17 @@ def list_installed() -> List[dict]:
return []
def update(ref: str):
return bool(system.run_cmd('flatpak update -y ' + ref))
def update(app_ref: str) -> bool:
return bool(system.run_cmd('flatpak update -y ' + app_ref))
def update_and_stream(app_ref: str):
"""
Updates the app reference and streams Flatpak output,
:param app_ref:
:return:
"""
return system.stream_cmd(['flatpak', 'update', '-y', app_ref])
def list_updates_as_str():