mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-11-06 23:40:29 +03:00
New metadata field: Vercode Operation
This commit is contained in:
parent
0c8283bc1a
commit
d507b2e894
3 changed files with 36 additions and 13 deletions
|
|
@ -333,6 +333,7 @@ def main():
|
|||
logmsg = None
|
||||
|
||||
tag = None
|
||||
msg = None
|
||||
mode = app['Update Check Mode']
|
||||
if mode == 'Tags':
|
||||
(version, vercode, tag) = check_tags(app, config['sdk_path'])
|
||||
|
|
@ -346,17 +347,21 @@ def main():
|
|||
(version, vercode) = check_http(app)
|
||||
elif mode == 'Static':
|
||||
version = None
|
||||
vercode = 'Checking disabled'
|
||||
msg = 'Checking disabled'
|
||||
elif mode == 'None':
|
||||
version = None
|
||||
vercode = 'Checking disabled'
|
||||
msg = 'Checking disabled'
|
||||
else:
|
||||
version = None
|
||||
vercode = 'Invalid update check method'
|
||||
msg = 'Invalid update check method'
|
||||
|
||||
if vercode and app['Vercode Operation']:
|
||||
op = app['Vercode Operation'].replace("%c", str(int(vercode)))
|
||||
vercode = str(eval(op))
|
||||
|
||||
updating = False
|
||||
if not version:
|
||||
print "..." + vercode
|
||||
print "...%s" % msg
|
||||
elif vercode == app['Current Version Code']:
|
||||
print "...up to date"
|
||||
else:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue