Skip to content

Commit 32ac271

Browse files
committed
Compile Click-specific guidelines
Reformat whole file to 80 characters limit Refs: https://github.com/pallets/click/pull/3239/changes#r3058361631 pallets/website#13 pallets/.github#3
1 parent 4a35225 commit 32ac271

1 file changed

Lines changed: 27 additions & 4 deletions

File tree

docs/contributing.md

Lines changed: 27 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,44 @@
11
# Contributing
22

3-
This is a quick reference for Click-specific development tasks. For setting up the development environment and the general contribution workflow, see the Pallets [quick reference](https://palletsprojects.com/contributing/quick/) and the [detailed contributing guide](https://palletsprojects.com/contributing/).
3+
This is a quick reference for Click-specific development
4+
tasks. For setting up the development environment and the
5+
general contribution workflow, see the Pallets [quick
6+
reference](https://palletsprojects.com/contributing/quick/)
7+
and the [detailed contributing
8+
guide](https://palletsprojects.com/contributing/).
49

510
## Extra Test Environments
611

712
Click includes some extra test environments:
813

9-
- `tox r -e stress` runs stress tests for race conditions in Click's test runner.
14+
- `tox r -e stress` runs stress tests for race conditions
15+
in Click's test runner.
1016

1117
```shell-session
1218
$ tox r -e stress
1319
```
1420
15-
- `tox r -e random` runs tests in parallel in a random order to detect test pollution.
21+
- `tox r -e random` runs tests in parallel in a random
22+
order to detect test pollution.
1623
1724
```shell-session
1825
$ tox r -e random
1926
```
2027
21-
- A CI workflow (`.github/workflows/test-flask.yaml`) runs Flask's test suite to catch downstream regressions.
28+
- A CI workflow (`.github/workflows/test-flask.yaml`)
29+
runs Flask's test suite to catch downstream
30+
regressions.
31+
32+
## Code Style
33+
34+
Avoid ternary expressions (`x if cond else y`): coverage
35+
cannot measure both branches. Use an explicit `if`/`else`
36+
block instead.
37+
38+
Do not add unnecessary dependencies. If a feature can be
39+
implemented with the standard library, do not pull in an
40+
external package for it.
41+
42+
## Formatting
43+
44+
Wrap lines in Markdown files at 80 characters.

0 commit comments

Comments
 (0)