-
Notifications
You must be signed in to change notification settings - Fork 10
Open
Description
this function is supposed to wrap click.command()
to allow it to be used on class methods, typically implementations of rats.cli.Container
. there was a first basic implementation that took the method's docstring and used it as the click command short help value, but it seems to not be working any more. it would also be nice if we could add the ability to specify any of the original click.command()
arguments, probably by accepting a simple **kwargs
and forwarding it along.
@cli.command()
def foo(self) -> None:
"""
This is the short description of the command, shown on parent command listings.
This is part of the larger description, shown on this command's --help text. This
docstring is a valid python apidoc docstring as parsed by our documentation tooling,
and should be usable as a decent default for generating a command's `--help` text.
"""
print("hello, world")
Metadata
Metadata
Assignees
Labels
No labels