Skip to content
Myr

Clarify Group invocation in quickstart

Before adoption: this commit came in with the history the project adopted, so no landing records it.

For new users and, as noted in #663 , especially those whose introduction to click may coincide with their introduction to python, it may not be clear that a Group is a callable. More specifically: the "root" of your command tree is the callable you actually want to invoke to run your CLI. closes #663

authored by Stephen Rosen · committed by Stephen Rosen · parent 123dd71 · Browse files · 1 file+6 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+6 added−0 removed

  • other:+6 added−0 removed

1 file+6 added−0 removed

modified:docs/quickstart.rst+6 added
225 unmodified lines
226 @cli.command()227 def dropdb():228 click.echo('Dropped the database')229230You would then invoke the :class:`Group` in your setuptools entry points or231other invocations::232233 if __name__ == '__main__':234 cli()235236Adding Parameters237-----------------238239To add parameters, use the :func:`option` and :func:`argument` decorators:
43 unmodified lines