Latest 10 apps (not entirely correct yet, missing some data)

This commit is contained in:
Ciaran Gultnieks 2012-01-22 14:03:56 +00:00
parent 3f02d0e126
commit ba353c71d4
2 changed files with 26 additions and 0 deletions

View file

@ -121,6 +121,7 @@ for logfile in glob.glob(os.path.join(logsdir,'access-*.log')):
if not apkname in unknownapks:
unknownapks.append(apkname)
# Calculate and write stats for total downloads...
f = open('stats/total_downloads_app.txt', 'w')
lst = []
alldownloads = 0
@ -133,6 +134,13 @@ for line in sorted(lst):
f.write(line + '\n')
f.close()
# Write list of latest apps added to the repo...
latest = knownapks.getlatest(10)
f = open('stats/latestapps.txt', 'w')
for app in latest:
f.write(app + '\n')
f.close()
if len(unknownapks) > 0:
print '\nUnknown apks:'
for apk in unknownapks: