mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-09-16 16:02:33 +03:00
fixed upper then lowercase sort, output as pretty xml as well
This commit is contained in:
parent
81a7de2d85
commit
06d83d12a7
1 changed files with 2 additions and 2 deletions
|
@ -185,7 +185,7 @@ for apk in apks:
|
||||||
print " " + apk['name'] + " - " + apk['version']
|
print " " + apk['name'] + " - " + apk['version']
|
||||||
|
|
||||||
#Sort the app list by name, then the web site doesn't have to by default:
|
#Sort the app list by name, then the web site doesn't have to by default:
|
||||||
apps = sorted(apps, key=lambda app: app['name'])
|
apps = sorted(apps, key=lambda app: app['name'].upper())
|
||||||
|
|
||||||
# Create the index
|
# Create the index
|
||||||
doc = Document()
|
doc = Document()
|
||||||
|
@ -275,7 +275,7 @@ for app in apps:
|
||||||
apps_disabled += 1
|
apps_disabled += 1
|
||||||
|
|
||||||
of = open(os.path.join('repo','index.xml'), 'wb')
|
of = open(os.path.join('repo','index.xml'), 'wb')
|
||||||
output = doc.toxml()
|
output = doc.toprettyxml(' ')
|
||||||
of.write(output)
|
of.write(output)
|
||||||
of.close()
|
of.close()
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue