Grab published abra apps json file

This commit is contained in:
decentral1se 2021-04-03 20:42:28 +02:00
parent 25090a8129
commit 2e159050e9
Signed by untrusted user who does not match committer: decentral1se
GPG Key ID: 92DAD76BD9567B8A

View File

@ -53,6 +53,19 @@ def _run_cmd(cmd, shell=False):
exit(1)
def get_published_apps_json():
"""Retrieve already published apps json."""
url = "https://abra-apps.cloud.autonomic.zone"
log.info(f"Retrieving {url}")
try:
return get(url, timeout=5).json()
except Exception as exception:
log.error(f"Failed to retrieve {url}, saw {str(exception)}")
return {}
def clone_all_apps():
"""Clone all Co-op Cloud apps to ~/.abra/apps."""
if not exists(CLONES_PATH):