Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 42 additions & 0 deletions .github/workflows/nightly.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Nightly race tests
on:
schedule:
- cron: '0 6 * * *'
workflow_dispatch:
permissions: {}
concurrency:
group: ${{ github.workflow }}
cancel-in-progress: false
jobs:
race-tests:
name: ${{ matrix.name }}
runs-on: ${{ matrix.os || 'ubuntu-latest' }}
strategy:
fail-fast: false
matrix:
include:
- {name: Random 3.14, python: '3.14', tox: random}
- {name: Random 3.14t, python: '3.14t', tox: random}
- {name: Random 3.13, python: '3.13', tox: random}
- {name: Random 3.12, python: '3.12', tox: random}
- {name: Random 3.11, python: '3.11', tox: random}
- {name: Random 3.10, python: '3.10', tox: random}
- {name: Random Windows, python: '3.14', tox: random, os: windows-latest}
- {name: Random Mac, python: '3.14', tox: random, os: macos-latest}
- {name: Stress 3.14, python: '3.14', tox: stress-py3.14}
- {name: Stress 3.14t, python: '3.14t', tox: stress-py3.14t}
- {name: Stress Mac 3.14t, python: '3.14t', tox: stress-py3.14t, os: macos-latest}
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- uses: astral-sh/setup-uv@cec208311dfd045dd5311c1add060b2062131d57 # v8.0.0
with:
enable-cache: true
prune-cache: false
- uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: ${{ matrix.python }}
- run: uv run --locked --no-default-groups --group dev tox run
env:
TOX_ENV: ${{ matrix.tox }}
40 changes: 40 additions & 0 deletions docs/documentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,46 @@ For subcommands, a short help snippet is generated. By default, it's the first s
invoke(cli, args=['--help'])
```

## Group Help Page

The group help prints sub commands, options, epilog help, and arguments, and prints them together.

```{eval-rst}
.. click:example::

import click

@click.group(
help="Example Click app with subcommands, options, and positional arguments.",
epilog=("Examples:\n\n\b\n python hello.py greet Alice --count 2\n"),
)
def cli() -> None:
"""Run the example CLI."""

@cli.command()
@click.argument("name")
@click.option(
"--count",
default=1,
show_default=True,
type=click.IntRange(1, None),
help="Number of greetings to print.",
)
@click.option(
"--greeting",
default="Hello",
show_default=True,
help="Greeting prefix to use.",
)
def greet(name: str, count: int, greeting: str) -> None:
"""Greet NAME one or more times."""
for _ in range(count):
click.echo(f"{greeting} {name}!")

.. click:run::
invoke(cli, args=['--help'])
```

## Command Epilog Help

The help epilog is printed at the end of the help and is useful for showing example command usages or referencing additional help resources.
Expand Down
Loading