channel_args = argparse.ArgumentParser(add_help=False)
channel_args.add_argument('--channel', choices=channel_by_name.keys(),
default='nightly',
help='''
Name of browser release channel (default: nightly). "stable"and"release" are
synonyms for the latest browser stable release; "beta"is the beta release; "dev"is only meaningful for Chrome (i.e. Chrome Dev); "nightly", "experimental", and"preview" are all synonyms for the latest available
development or trunk release. (For WebDriver installs, we attempt to select an
appropriate, compatible version for the latest browser release on the selected
channel.) This flag overrides --browser-channel.''')
def get_parser():
parser = argparse.ArgumentParser(
parents=[channel_args],
description="Install a given browser or webdriver frontend.")
parser.add_argument('browser', choices=['firefox', 'chrome', 'chromium', 'servo', 'safari', 'wktr'],
help='name of web browser product')
parser.add_argument('component', choices=['browser', 'webdriver'],
help='name of component')
parser.add_argument('--download-only', action="store_true",
help="Download the selected component but don't install it")
parser.add_argument('--rename',
help="Filename, excluding extension for downloaded archive " "(only with --download-only)")
parser.add_argument('-d', '--destination',
help='filesystem directory to place the component')
parser.add_argument('--revision',
help='Chromium revision to install from snapshots') return parser
if channel != kwargs["channel"]:
logger.info("Interpreting channel '%s' as '%s'", kwargs["channel"], channel)
if destination isNone: if venv: if kwargs["component"] == "browser":
destination = venv.path else:
destination = venv.bin_path else: raise argparse.ArgumentError(None, "No --destination argument, and no default for the environment")
if kwargs["revision"] isnotNoneand browser != "chromium": raise argparse.ArgumentError(None, "--revision flag cannot be used for non-Chromium browsers.")
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.