index.rst
This file
Path
docs/index.rst
145 lines · 2.7 KiB
Last changed by
Add upgrade guide section.Edward Gbefore adoption73117fe
History of this fileTake it
The walk stopped after 200 commits: lines older than fb43272 point at it.
Bump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
lines 1–5why, one step back1.. rst-class:: hide-header23Welcome to Click4================5svg logoDavid Lordbefore adoption2865034
line 6why, one step back6.. image:: _static/click-name.svgBump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
line 7why, one step back7 :align: centernew logo (#2974)David Lordbefore adoptiond2e0fb5
line 8why, one step back8 :height: 200pxBump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
lines 9–59why, one step back910Click is a Python package for creating beautiful command line interfaces11in a composable way with as little code as necessary. It's the "Command12Line Interface Creation Kit". It's highly configurable but comes with13sensible defaults out of the box.1415It aims to make the process of writing command line tools quick and fun16while also preventing any frustration caused by the inability to implement17an intended CLI API.1819Click in three points:2021- arbitrary nesting of commands22- automatic help page generation23- supports lazy loading of subcommands at runtime2425What does it look like? Here is an example of a simple Click program:2627.. click:example::2829 import click3031 @click.command()32 @click.option('--count', default=1, help='Number of greetings.')33 @click.option('--name', prompt='Your name',34 help='The person to greet.')35 def hello(count, name):36 """Simple program that greets NAME for a total of COUNT times."""37 for x in range(count):38 click.echo(f"Hello {name}!")3940 if __name__ == '__main__':41 hello()4243And what it looks like when run:4445.. click:run::4647 invoke(hello, ['--count=3'], prog_name='python hello.py', input='John\n')4849It automatically generates nicely formatted help pages:5051.. click:run::5253 invoke(hello, ['--help'], prog_name='python hello.py')5455You can get the library directly from PyPI::5657 pip install click5859DocumentationAlign docs index header levels. (#2951)Rowlando13before adoption3a917b9
line 60why, one step back60==============Bump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
line 61why, one step back61Make faqs section. Add the first question about windows shell expansion. (#2927)Rowlando13before adoption9ce34f2
lines 62–66why, one step back62.. toctree::63 :maxdepth: 26465 faqs66Organize docs along diatxis categories. (#2898)Rowlando13before adoptionb88c484
line 67why, one step back67TutorialsAlign docs index header levels. (#2951)Rowlando13before adoption3a917b9
line 68why, one step back68------------Bump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
line 69why, one step back69.. toctree::Organize docs along diatxis categories. (#2898)Rowlando13before adoptionb88c484
line 70why, one step back70 :maxdepth: 1Bump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
lines 71–72why, one step back7172 quickstartMerge stable into main (#2799)Rowlando13before adoptiond791537
line 73why, one step back73 virtualenvOrganize docs along diatxis categories. (#2898)Rowlando13before adoptionb88c484
lines 74–75why, one step back7475How to GuidesAlign docs index header levels. (#2951)Rowlando13before adoption3a917b9
line 76why, one step back76---------------Organize docs along diatxis categories. (#2898)Rowlando13before adoptionb88c484
lines 77–80why, one step back77.. toctree::78 :maxdepth: 17980 entry-pointsMerge stable into main (#2799)Rowlando13before adoptiond791537
line 81why, one step back81 setuptoolsAdd upgrade guide section.Edward Gbefore adoption73117fe
line 82why, one step back82 upgrade-guidesAdd a doc for supporting 8.1.x|8.2.0 (#2929)David Lordbefore adoption2d610e3
line 83why, one step back83 support-multiple-versionsOrganize docs along diatxis categories. (#2898)Rowlando13before adoptionb88c484
lines 84–85why, one step back8485Conceptual GuidesAlign docs index header levels. (#2951)Rowlando13before adoption3a917b9
line 86why, one step back86-------------------Organize docs along diatxis categories. (#2898)Rowlando13before adoptionb88c484
lines 87–89why, one step back87.. toctree::88 :maxdepth: 189Add Best practices section (#3127)Rowlando13before adoption0b5c6b7
line 90why, one step back90 design-opinionsOrganize docs along diatxis categories. (#2898)Rowlando13before adoptionb88c484
line 91why, one step back91 whyMake distinct sections for advanced patterns and extending click. (#2925)Rowlando13before adoption2aecb2d
line 92why, one step back92 click-conceptsOrganize docs along diatxis categories. (#2898)Rowlando13before adoptionb88c484
lines 93–94why, one step back9394General ReferenceAlign docs index header levels. (#2951)Rowlando13before adoption3a917b9
line 95why, one step back95--------------------Organize docs along diatxis categories. (#2898)Rowlando13before adoptionb88c484
lines 96–99why, one step back9697.. toctree::98 :maxdepth: 199Bump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
line 100why, one step back100 parametersRewrite first half of options docs (#2825)Rowlando13before adoption82089af
line 101why, one step back101 parameter-typesRewrite help page section. (#2821)Rowlando13before adoption8a47580
line 102why, one step back102 optionsRewrite first half of options docs (#2825)Rowlando13before adoption82089af
lines 103–104why, one step back103 option-decorators104 argumentsRewrite Commands and Groups docs. (#2838)Rowlando13before adoption0bf333e
line 105why, one step back105 commands-and-groupsBump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
lines 106–107why, one step back106 commands107 documentationRewrite help page section. (#2821)Rowlando13before adoption8a47580
line 108why, one step back108 promptsMerge `stable` into `main`; Release 8.2.0 (#2873)Rowlando13before adoptionb7c0ab4
line 109why, one step back109 handling-filesBump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
line 110why, one step back110 advancedMake distinct sections for advanced patterns and extending click. (#2925)Rowlando13before adoption2aecb2d
lines 111–112why, one step back111 complex112 extending-clickBump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
lines 113–116why, one step back113 testing114 utils115 shell-completion116 exceptionsVery short description of exit codes and how to access them (#3112)Rowlando13before adoption868b611
line 117why, one step back117 command-line-referenceBump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
lines 118–121why, one step back118 unicode-support119 wincmd120121API ReferenceAlign docs index header levels. (#2951)Rowlando13before adoption3a917b9
line 122why, one step back122-------------------Bump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
lines 123–128why, one step back123124.. toctree::125 :maxdepth: 2126127 api128Organize docs along diatxis categories. (#2898)Rowlando13before adoptionb88c484
line 129why, one step back129About ProjectAlign docs index header levels. (#2951)Rowlando13before adoption3a917b9
line 130why, one step back130===============Bump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
line 131why, one step back131Organize docs along diatxis categories. (#2898)Rowlando13before adoptionb88c484
lines 132–139why, one step back132* This documentation is structured according to `Diataxis <https://diataxis.fr/>`_133134* `Version Policy <https://palletsprojects.com/versions>`_135136* `Contributing <https://palletsprojects.com/contributing/>`_137138* `Donate <https://palletsprojects.com/donate>`_139Bump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
line 140why, one step back140.. toctree::Organize docs along diatxis categories. (#2898)Rowlando13before adoptionb88c484
line 141why, one step back141 :maxdepth: 1Bump actions/cache from 3.0.5 to 3.0.8 (#2349)dependabot[bot]before adoptionfb43272
lines 142–145why, one step back142143 contrib144 license145 changes