mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-11-09 17:00:12 +01:00
Add Dogecoin support, some None fixes
This commit is contained in:
parent
23f5a4b1ad
commit
4b8ab5edb2
@ -93,6 +93,11 @@ valuetypes = {
|
|||||||
[ "Litecoin" ],
|
[ "Litecoin" ],
|
||||||
[ ]),
|
[ ]),
|
||||||
|
|
||||||
|
'dogecoin' : FieldType("Dogecoin address",
|
||||||
|
r'^D[a-zA-Z0-9]{33}$', None,
|
||||||
|
[ "Dogecoin" ],
|
||||||
|
[ ]),
|
||||||
|
|
||||||
'Bool' : FieldType("Boolean",
|
'Bool' : FieldType("Boolean",
|
||||||
['Yes', 'No'], None,
|
['Yes', 'No'], None,
|
||||||
[ "Requires Root" ],
|
[ "Requires Root" ],
|
||||||
@ -485,6 +490,7 @@ def parse_metadata(metafile):
|
|||||||
thisinfo['FlattrID'] = None
|
thisinfo['FlattrID'] = None
|
||||||
thisinfo['Bitcoin'] = None
|
thisinfo['Bitcoin'] = None
|
||||||
thisinfo['Litecoin'] = None
|
thisinfo['Litecoin'] = None
|
||||||
|
thisinfo['Dogecoin'] = None
|
||||||
thisinfo['Disabled'] = None
|
thisinfo['Disabled'] = None
|
||||||
thisinfo['AntiFeatures'] = None
|
thisinfo['AntiFeatures'] = None
|
||||||
thisinfo['Archive Policy'] = None
|
thisinfo['Archive Policy'] = None
|
||||||
@ -657,6 +663,8 @@ def write_metadata(dest, app):
|
|||||||
writefield('Bitcoin')
|
writefield('Bitcoin')
|
||||||
if app['Litecoin']:
|
if app['Litecoin']:
|
||||||
writefield('Litecoin')
|
writefield('Litecoin')
|
||||||
|
if app['Dogecoin']:
|
||||||
|
writefield('Dogecoin')
|
||||||
mf.write('\n')
|
mf.write('\n')
|
||||||
if app['Name']:
|
if app['Name']:
|
||||||
writefield('Name')
|
writefield('Name')
|
||||||
|
@ -56,7 +56,7 @@ def update_wiki(apps, apks):
|
|||||||
if app['AntiFeatures']:
|
if app['AntiFeatures']:
|
||||||
for af in app['AntiFeatures'].split(','):
|
for af in app['AntiFeatures'].split(','):
|
||||||
wikidata += '{{AntiFeature|' + af + '}}\n'
|
wikidata += '{{AntiFeature|' + af + '}}\n'
|
||||||
wikidata += '{{App|id=%s|name=%s|added=%s|lastupdated=%s|source=%s|tracker=%s|web=%s|donate=%s|flattr=%s|bitcoin=%s|litecoin=%s|license=%s|root=%s}}\n'%(
|
wikidata += '{{App|id=%s|name=%s|added=%s|lastupdated=%s|source=%s|tracker=%s|web=%s|donate=%s|flattr=%s|bitcoin=%s|litecoin=%s|dogecoin=%s|license=%s|root=%s}}\n'%(
|
||||||
app['id'],
|
app['id'],
|
||||||
app['Name'],
|
app['Name'],
|
||||||
time.strftime('%Y-%m-%d', app['added']) if 'added' in app else '',
|
time.strftime('%Y-%m-%d', app['added']) if 'added' in app else '',
|
||||||
@ -68,6 +68,7 @@ def update_wiki(apps, apks):
|
|||||||
app['FlattrID'],
|
app['FlattrID'],
|
||||||
app['Bitcoin'],
|
app['Bitcoin'],
|
||||||
app['Litecoin'],
|
app['Litecoin'],
|
||||||
|
app['Dogecoin'],
|
||||||
app['License'],
|
app['License'],
|
||||||
app.get('Requires Root', 'No'))
|
app.get('Requires Root', 'No'))
|
||||||
|
|
||||||
@ -484,7 +485,7 @@ def make_index(apps, apks, repodir, archive, categories):
|
|||||||
addElement('description', config['repo_description'], doc, repoel)
|
addElement('description', config['repo_description'], doc, repoel)
|
||||||
repoel.setAttribute("timestamp", str(int(time.time())))
|
repoel.setAttribute("timestamp", str(int(time.time())))
|
||||||
|
|
||||||
if config['repo_keyalias'] is not None:
|
if config['repo_keyalias']:
|
||||||
|
|
||||||
# Generate a certificate fingerprint the same way keytool does it
|
# Generate a certificate fingerprint the same way keytool does it
|
||||||
# (but with slightly different formatting)
|
# (but with slightly different formatting)
|
||||||
@ -538,7 +539,7 @@ def make_index(apps, apks, repodir, archive, categories):
|
|||||||
addElement('lastupdated', time.strftime('%Y-%m-%d', app['lastupdated']), doc, apel)
|
addElement('lastupdated', time.strftime('%Y-%m-%d', app['lastupdated']), doc, apel)
|
||||||
addElement('name', app['Name'], doc, apel)
|
addElement('name', app['Name'], doc, apel)
|
||||||
addElement('summary', app['Summary'], doc, apel)
|
addElement('summary', app['Summary'], doc, apel)
|
||||||
if app['icon'] is not None:
|
if app['icon']:
|
||||||
addElement('icon', app['icon'], doc, apel)
|
addElement('icon', app['icon'], doc, apel)
|
||||||
def linkres(link):
|
def linkres(link):
|
||||||
for app in apps:
|
for app in apps:
|
||||||
@ -558,13 +559,15 @@ def make_index(apps, apks, repodir, archive, categories):
|
|||||||
addElement('web', app['Web Site'], doc, apel)
|
addElement('web', app['Web Site'], doc, apel)
|
||||||
addElement('source', app['Source Code'], doc, apel)
|
addElement('source', app['Source Code'], doc, apel)
|
||||||
addElement('tracker', app['Issue Tracker'], doc, apel)
|
addElement('tracker', app['Issue Tracker'], doc, apel)
|
||||||
if app['Donate'] is not None:
|
if app['Donate']:
|
||||||
addElement('donate', app['Donate'], doc, apel)
|
addElement('donate', app['Donate'], doc, apel)
|
||||||
if app['Bitcoin'] is not None:
|
if app['Bitcoin']:
|
||||||
addElement('bitcoin', app['Bitcoin'], doc, apel)
|
addElement('bitcoin', app['Bitcoin'], doc, apel)
|
||||||
if app['Litecoin'] is not None:
|
if app['Litecoin']:
|
||||||
addElement('litecoin', app['Litecoin'], doc, apel)
|
addElement('litecoin', app['Litecoin'], doc, apel)
|
||||||
if app['FlattrID'] is not None:
|
if app['Dogecoin']:
|
||||||
|
addElement('dogecoin', app['Dogecoin'], doc, apel)
|
||||||
|
if app['FlattrID']:
|
||||||
addElement('flattr', app['FlattrID'], doc, apel)
|
addElement('flattr', app['FlattrID'], doc, apel)
|
||||||
|
|
||||||
# These elements actually refer to the current version (i.e. which
|
# These elements actually refer to the current version (i.e. which
|
||||||
|
Loading…
Reference in New Issue
Block a user