1
0
Fork 0
mirror of https://github.com/YunoHost/apps.git synced 2024-09-03 20:06:07 +02:00

[mod] import at the debigging of the file, it's not yunohost codebase

This commit is contained in:
Laurent Peuch 2018-05-27 08:52:26 +02:00
parent ae21cb2c64
commit 6b321066f0

View file

@ -5,6 +5,7 @@ import sys
import json
from urllib2 import urlopen
from urlparse import urlparse
states = {
1: "notworking",
@ -50,7 +51,6 @@ if __name__ == '__main__':
git_data = json.load(urlopen("https://api.github.com/repos/%(owner)s/%(repo)s/commits" % {"owner": owner, "repo": repo}))
revision = git_data[0]["sha"]
else:
from urlparse import urlparse
parsed_uri = urlparse( url )
base_url = '{uri.scheme}://{uri.netloc}/'.format(uri=parsed_uri)
# Try with gitlab api