diff options
author | Kevin Yap <me@kevinyap.ca> | 2014-06-05 19:23:05 -0700 |
---|---|---|
committer | Kevin Yap <me@kevinyap.ca> | 2014-06-05 19:23:05 -0700 |
commit | 10977b925e67c48261bfd6eaf71e7ba6a3bb7374 (patch) | |
tree | 4e52a49b221b42dcf56a99385c0e6608659b506f /docs/documentation.rst | |
parent | 39b89928ea93872f781ff19259239ffc4b0a63f2 (diff) | |
download | click-10977b925e67c48261bfd6eaf71e7ba6a3bb7374.tar.gz |
Minor documentation fixes
Diffstat (limited to 'docs/documentation.rst')
-rw-r--r-- | docs/documentation.rst | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/docs/documentation.rst b/docs/documentation.rst index 65ae11f..48c9ba5 100644 --- a/docs/documentation.rst +++ b/docs/documentation.rst @@ -5,13 +5,14 @@ Documenting Scripts Click makes it very easy to document your command line tools. First of all, it automatically generates help pages for you. While these are -currently not customizable in layout, all of the text can be changed. +currently not customizable in terms of their layout, all of the text +can be changed. Help Texts ---------- -Commands and options accept help arguments. In the case of commands, the doc -string of the function is automatically used if provided. +Commands and options accept help arguments. In the case of commands, the +docstring of the function is automatically used if provided. Simple example: @@ -39,9 +40,9 @@ by name. Preventing Rewrapping --------------------- -The default behavior of click is to rewrap text to work correctly for the -width of the terminal. In some circumstances, this can become a problem. -The main issue is showing code examples where newlines are significant. +The default behavior of click is to rewrap text based on the width of the +terminal. In some circumstances, this can become a problem. The main issue +is when showing code examples, where newlines are significant. Rewrapping can be disabled on a per-paragraph basis by adding a line with solely the ``\b`` escape marker in it. This line will be removed from the @@ -135,16 +136,16 @@ Help Parameter Customization .. versionadded:: 2.0 -The help parameter is very special in how it's implemented in click. +The help parameter is implemented in click in a very special manner. Unlike regular parameters it's automatically added by click for any command and it performs automatic conflict resolution. By default it's -called ``--help`` but this can be changed. If a command itself implements -a parameter with the same name the default help parameter stops accepting +called ``--help``, but this can be changed. If a command itself implements +a parameter with the same name, the default help parameter stops accepting it. There is a context setting that can be used to override the names of the help parameters called :attr:`~Context.help_option_names`. This example changes the default parameters to ``-h`` and ``--help`` -instad of just ``--help``: +instead of just ``--help``: .. click:example:: |