Fix metavar for package CLI

This commit is contained in:
Ivan Kravets
2020-05-27 16:20:02 +03:00
parent c06859aa9f
commit d38f5aca5c
2 changed files with 11 additions and 3 deletions

View File

@ -36,7 +36,7 @@ def cli():
@cli.command("pack", short_help="Create a tarball from a package") @cli.command("pack", short_help="Create a tarball from a package")
@click.argument("package", required=True, metavar="[source directory, tar.gz or zip]") @click.argument("package", required=True, metavar="<source directory, tar.gz or zip>")
def package_pack(package): def package_pack(package):
p = PackagePacker(package) p = PackagePacker(package)
archive_path = p.pack() archive_path = p.pack()
@ -44,7 +44,7 @@ def package_pack(package):
@cli.command("publish", short_help="Publish a package to the registry") @cli.command("publish", short_help="Publish a package to the registry")
@click.argument("package", required=True, metavar="[source directory, tar.gz or zip]") @click.argument("package", required=True, metavar="<source directory, tar.gz or zip>")
@click.option( @click.option(
"--owner", "--owner",
help="PIO Account username (can be organization username). " help="PIO Account username (can be organization username). "

View File

@ -146,7 +146,15 @@ class MeasurementProtocol(TelemetryBase):
return return
cmd_path = args[:1] cmd_path = args[:1]
if args[0] in ("account", "device", "platform", "project", "settings",): if args[0] in (
"account",
"device",
"platform",
"package",
"project",
"settings",
"system",
):
cmd_path = args[:2] cmd_path = args[:2]
if args[0] == "lib" and len(args) > 1: if args[0] == "lib" and len(args) > 1:
lib_subcmds = ( lib_subcmds = (