You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .github/CONTRIBUTING.md
+63-63
Original file line number
Diff line number
Diff line change
@@ -34,7 +34,67 @@ The official tag is `python-attrs` and helping out in support frees us up to imp
34
34
If you have problems to test something, open anyway and ask for advice.
35
35
In some situations, we may agree to add an `# pragma: no cover`.
36
36
- Once you've addressed review feedback, make sure to bump the pull request with a short note, so we know you're done.
37
-
- Don’t break backwards compatibility.
37
+
- Don’t break backwards-compatibility.
38
+
39
+
40
+
## Local Development Environment
41
+
42
+
You can (and should) run our test suite using [*tox*].
43
+
However, you’ll probably want a more traditional environment as well.
44
+
We highly recommend to develop using the latest Python release because we try to take advantage of modern features whenever possible.
45
+
46
+
First create a [virtual environment](https://virtualenv.pypa.io/) so you don't break your system-wide Python installation.
47
+
It’s out of scope for this document to list all the ways to manage virtual environments in Python, but if you don’t already have a pet way, take some time to look at tools like [*direnv*](https://hynek.me/til/python-project-local-venvs/), [*virtualfish*](https://virtualfish.readthedocs.io/), and [*virtualenvwrapper*](https://virtualenvwrapper.readthedocs.io/).
48
+
49
+
Next, get an up-to-date checkout of the `attrs` repository:
Change into the newly created directory and **after activating your virtual environment** install an editable version of `attrs` along with its tests and docs requirements:
The built documentation can then be found in `docs/_build/html/`.
83
+
84
+
To avoid committing code that violates our style guide, we strongly advise you to install [*pre-commit*][^dev] hooks:
85
+
86
+
```console
87
+
$ pre-commit install
88
+
```
89
+
90
+
You can also run them anytime (as our *tox* does) using:
91
+
92
+
```console
93
+
$ pre-commit run --all-files
94
+
```
95
+
96
+
[^dev]: *pre-commit* should have been installed into your virtualenv automatically when you ran `pip install -e '.[dev]'` above.
97
+
If *pre-commit* is missing, your probably need to run `pip install -e '.[dev]'` again.
38
98
39
99
40
100
## Code
@@ -54,7 +114,7 @@ The official tag is `python-attrs` and helping out in support frees us up to imp
54
114
```
55
115
- If you add or change public APIs, tag the docstring using `.. versionadded:: 16.0.0 WHAT` or `.. versionchanged:: 16.2.0 WHAT`.
56
116
- We use [*isort*](https://github.com/PyCQA/isort) to sort our imports, and we use [*Black*](https://github.com/psf/black) with line length of 79 characters to format our code.
57
-
As long as you run our full [*tox*] suite before committing, or install our [*pre-commit*] hooks (ideally you'll do both – see [*Local Development Environment*](#local-development-environment)below), you won't have to spend any time on formatting your code at all.
117
+
As long as you run our full [*tox*] suite before committing, or install our [*pre-commit*] hooks (ideally you'll do both – see [*Local Development Environment*](#local-development-environment)above), you won't have to spend any time on formatting your code at all.
58
118
If you don't, [CI] will catch it for you – but that seems like a waste of your time!
59
119
60
120
@@ -81,7 +141,7 @@ The official tag is `python-attrs` and helping out in support frees us up to imp
81
141
82
142
## Documentation
83
143
84
-
- Use [semantic newlines] in [*reStructuredText*] files (files ending in `.rst`):
144
+
- Use [semantic newlines] in [*reStructuredText*]and [*Markdown*](https://docs.github.com/en/get-started/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax)files (files ending in `.rst` and `.md`):
85
145
86
146
```rst
87
147
This is a sentence.
@@ -152,66 +212,6 @@ or:
152
212
``tox -e changelog`` will render the current changelog to the terminal if you have any doubts.
153
213
154
214
155
-
## Local Development Environment
156
-
157
-
You can (and should) run our test suite using [*tox*].
158
-
However, you’ll probably want a more traditional environment as well.
159
-
We highly recommend to develop using the latest Python release because we try to take advantage of modern features whenever possible.
160
-
161
-
First create a [virtual environment](https://virtualenv.pypa.io/) so you don't break your system-wide Python installation.
162
-
It’s out of scope for this document to list all the ways to manage virtual environments in Python, but if you don’t already have a pet way, take some time to look at tools like [*direnv*](https://hynek.me/til/python-project-local-venvs/), [*virtualfish*](https://virtualfish.readthedocs.io/), and [*virtualenvwrapper*](https://virtualenvwrapper.readthedocs.io/).
163
-
164
-
Next, get an up to date checkout of the `attrs` repository:
Change into the newly created directory and **after activating your virtual environment** install an editable version of `attrs` along with its tests and docs requirements:
The built documentation can then be found in `docs/_build/html/`.
198
-
199
-
To avoid committing code that violates our style guide, we strongly advise you to install [*pre-commit*][^dev] hooks:
200
-
201
-
```console
202
-
$ pre-commit install
203
-
```
204
-
205
-
You can also run them anytime (as our tox does) using:
206
-
207
-
```console
208
-
$ pre-commit run --all-files
209
-
```
210
-
211
-
[^dev]: *pre-commit* should have been installed into your virtualenv automatically when you ran `pip install -e '.[dev]'` above.
212
-
If *pre-commit* is missing, your probably need to run `pip install -e '.[dev]'` again.
213
-
214
-
215
215
## Governance
216
216
217
217
`attrs` is maintained by [team of volunteers](https://github.com/python-attrs) that is always open to new members that share our vision of a fast, lean, and magic-free library that empowers programmers to write better code with less effort.
0 commit comments