mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-11-12 02:00:28 +03:00
Merge commit 'refs/merge-requests/86' of git://gitorious.org/f-droid/fdroidserver into merge-requests/86
This commit is contained in:
commit
bc4240ca30
4 changed files with 34 additions and 12 deletions
|
|
@ -130,12 +130,14 @@ def main():
|
|||
# Get all apps...
|
||||
apps = common.read_metadata(options.verbose)
|
||||
|
||||
for app in apps:
|
||||
# Filter apps according to command-line options
|
||||
if options.package:
|
||||
apps = [app for app in apps if app['id'] == options.package]
|
||||
if len(apps) == 0:
|
||||
print "No such package"
|
||||
sys.exit(1)
|
||||
|
||||
if options.package and options.package != app['id']:
|
||||
# Silent skip...
|
||||
pass
|
||||
else:
|
||||
for app in apps:
|
||||
print "Processing " + app['id'] + '...'
|
||||
|
||||
mode = app['Update Check Mode']
|
||||
|
|
|
|||
|
|
@ -36,11 +36,20 @@ def main():
|
|||
parser = OptionParser()
|
||||
parser.add_option("-v", "--verbose", action="store_true", default=False,
|
||||
help="Spew out even more information than normal")
|
||||
parser.add_option("-p", "--package", default=None,
|
||||
help="Build only the specified package")
|
||||
(options, args) = parser.parse_args()
|
||||
|
||||
# Get all apps...
|
||||
apps = common.read_metadata(options.verbose)
|
||||
|
||||
# Filter apps according to command-line options
|
||||
if options.package:
|
||||
apps = [app for app in apps if app['id'] == options.package]
|
||||
if len(apps) == 0:
|
||||
print "No such package"
|
||||
sys.exit(1)
|
||||
|
||||
for app in apps:
|
||||
print "Writing " + app['id']
|
||||
common.write_metadata(os.path.join('metadata', app['id']) + '.txt', app)
|
||||
|
|
|
|||
|
|
@ -50,6 +50,13 @@ def main():
|
|||
# Get all apps...
|
||||
apps = common.read_metadata(options.verbose)
|
||||
|
||||
# Filter apps according to command-line options
|
||||
if options.package:
|
||||
apps = [app for app in apps if app['id'] == options.package]
|
||||
if len(apps) == 0:
|
||||
print "No such package"
|
||||
sys.exit(1)
|
||||
|
||||
html_parser = HTMLParser.HTMLParser()
|
||||
|
||||
problems = []
|
||||
|
|
@ -59,9 +66,7 @@ def main():
|
|||
for app in apps:
|
||||
|
||||
skip = False
|
||||
if options.package and app['id'] != options.package:
|
||||
skip = True
|
||||
elif app['Disabled']:
|
||||
if app['Disabled']:
|
||||
print "Skipping %s: disabled" % app['id']
|
||||
skip = True
|
||||
elif not app['builds']:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue