1
0
mirror of https://gitlab.com/fdroid/fdroidserver.git synced 2024-11-09 17:00:12 +01:00

stats: simpler repo type logic

This commit is contained in:
Daniel Martí 2014-08-16 11:42:51 +02:00
parent 51c93c9576
commit eb81375630

View File

@ -214,13 +214,9 @@ def main():
logging.info("Processing repo types...") logging.info("Processing repo types...")
repotypes = Counter() repotypes = Counter()
for app in metaapps: for app in metaapps:
if len(app['Repo Type']) == 0: rtype = app['Repo Type'] or 'none'
rtype = 'none' if rtype == 'srclib':
else:
if app['Repo Type'] == 'srclib':
rtype = common.getsrclibvcs(app['Repo']) rtype = common.getsrclibvcs(app['Repo'])
else:
rtype = app['Repo Type']
repotypes[rtype] += 1 repotypes[rtype] += 1
f = open('stats/repotypes.txt', 'w') f = open('stats/repotypes.txt', 'w')
for rtype in repotypes: for rtype in repotypes: