"""Parse the command line. Returns options, parser."""
parser = ArgumentParser(usage="%(prog)s [options] [APPID[:VERCODE] [APPID[:VERCODE] ...]]")
+ common.setup_global_opts(parser)
parser.add_argument("appid", nargs='*', help="app-id with optional versioncode in the form APPID[:VERCODE]")
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
parser.add_argument("-l", "--latest", action="store_true", default=False,
help="Build only the latest version of each package")
parser.add_argument("-s", "--stop", action="store_true", default=False,
# Parse command line...
parser = ArgumentParser(usage="%(prog)s [options] [APPID [APPID ...]]")
+ common.setup_global_opts(parser)
parser.add_argument("appid", nargs='*', help="app-id to check for updates")
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
parser.add_argument("--auto", action="store_true", default=False,
help="Process auto-updates")
parser.add_argument("--autoonly", action="store_true", default=False,
}
+def setup_global_opts(parser):
+ parser.add_argument("-v", "--verbose", action="store_true", default=False,
+ help="Spew out even more information than normal")
+ parser.add_argument("-q", "--quiet", action="store_true", default=False,
+ help="Restrict output to warnings and errors")
+
+
def fill_config_defaults(thisconfig):
for k, v in default_config.items():
if k not in thisconfig:
# Parse command line...
parser = ArgumentParser(usage="%(prog)s [options]")
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
+ common.setup_global_opts(parser)
options = parser.parse_args()
config = common.read_config(options)
# Parse command line...
parser = ArgumentParser()
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
+ common.setup_global_opts(parser)
parser.add_argument("-u", "--url", default=None,
help="Project URL to import from.")
parser.add_argument("-s", "--subdir", default=None,
# Parse command line...
parser = ArgumentParser()
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
+ common.setup_global_opts(parser)
parser.add_argument("-d", "--distinguished-name", default=None,
help="X.509 'Distiguished Name' used when generating keys")
parser.add_argument("--keystore", default=None,
# Parse command line...
parser = ArgumentParser(usage="%(prog)s [options] [APPID[:VERCODE] [APPID[:VERCODE] ...]]")
+ common.setup_global_opts(parser)
parser.add_argument("appid", nargs='*', help="app-id with optional versioncode in the form APPID[:VERCODE]")
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
parser.add_argument("-a", "--all", action="store_true", default=False,
help="Install all signed applications available")
options = parser.parse_args()
# Parse command line...
parser = ArgumentParser(usage="%(prog)s [options] [APPID [APPID ...]]")
+ common.setup_global_opts(parser)
parser.add_argument("appid", nargs='*', help="app-id in the form APPID")
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
options = parser.parse_args()
config = common.read_config(options)
# Parse command line...
parser = ArgumentParser(usage="%(prog)s [options] "
"[APPID[:VERCODE] [APPID[:VERCODE] ...]]")
+ common.setup_global_opts(parser)
parser.add_argument("appid", nargs='*', help="app-id with optional versioncode in the form APPID[:VERCODE]")
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
options = parser.parse_args()
config = common.read_config(options)
def main():
parser = ArgumentParser(usage="%(prog)s")
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
+ common.setup_global_opts(parser)
parser.parse_args()
common.read_config(None)
# Parse command line...
parser = ArgumentParser(usage="%(prog)s [options] [APPID [APPID ...]]")
+ common.setup_global_opts(parser)
parser.add_argument("appid", nargs='*', help="app-id in the form APPID")
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
options = parser.parse_args()
config = common.read_config(options)
# Parse command line...
parser = ArgumentParser(usage="%(prog)s [options] [APPID[:VERCODE] [APPID[:VERCODE] ...]]")
+ common.setup_global_opts(parser)
parser.add_argument("appid", nargs='*', help="app-id with optional versioncode in the form APPID[:VERCODE]")
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
options = parser.parse_args()
config = common.read_config(options)
# Parse command line...
parser = ArgumentParser()
+ common.setup_global_opts(parser)
parser.add_argument("command", help="command to execute, either 'init' or 'update'")
parser.add_argument("-i", "--identity-file", default=None,
help="Specify an identity file to provide to SSH for rsyncing")
help="Specify a local folder to sync the repo to")
parser.add_argument("--sync-from-local-copy-dir", action="store_true", default=False,
help="Before uploading to servers, sync from local copy dir")
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
parser.add_argument("--no-checksum", action="store_true", default=False,
help="Don't use rsync checksums")
options = parser.parse_args()
# Parse command line...
parser = ArgumentParser(usage="%(prog)s [options]")
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
+ common.setup_global_opts(parser)
options = parser.parse_args()
config = common.read_config(options)
# Parse command line...
parser = ArgumentParser()
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
+ common.setup_global_opts(parser)
parser.add_argument("-d", "--download", action="store_true", default=False,
help="Download logs we don't have")
parser.add_argument("--recalc", action="store_true", default=False,
# Parse command line...
parser = ArgumentParser()
+ common.setup_global_opts(parser)
parser.add_argument("--create-key", action="store_true", default=False,
help="Create a repo signing key in a keystore")
parser.add_argument("-c", "--create-metadata", action="store_true", default=False,
help="Create skeleton metadata files that are missing")
parser.add_argument("--delete-unknown", action="store_true", default=False,
help="Delete APKs without metadata from the repo")
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
parser.add_argument("-b", "--buildreport", action="store_true", default=False,
help="Report on build data status")
parser.add_argument("-i", "--interactive", default=False, action="store_true",
# Parse command line...
parser = ArgumentParser(usage="%(prog)s [options] [APPID[:VERCODE] [APPID[:VERCODE] ...]]")
+ common.setup_global_opts(parser)
parser.add_argument("appid", nargs='*', help="app-id with optional versioncode in the form APPID[:VERCODE]")
- parser.add_argument("-v", "--verbose", action="store_true", default=False,
- help="Spew out even more information than normal")
- parser.add_argument("-q", "--quiet", action="store_true", default=False,
- help="Restrict output to warnings and errors")
options = parser.parse_args()
config = common.read_config(options)