Skip to content

Commit 2c40a5f

Browse files
committed
docs: improve contrib
1 parent 85d32a3 commit 2c40a5f

File tree

2 files changed

+22
-24
lines changed

2 files changed

+22
-24
lines changed

CONTRIBUTING.md

+21-24
Original file line numberDiff line numberDiff line change
@@ -2,59 +2,56 @@
22

33
We are happy to accept contributions to `mplhep` via Pull Requests to the GitHub repo. To get started fork the repo.
44

5-
## Pull Requests
6-
7-
### Pull Requests Procedure
8-
9-
If you would like to make a pull request please:
10-
11-
1. Make a fork of the project
12-
2. Install `pre-commit` and the project's `pre-commit` hooks
13-
3. Commit your changes to a feature branch of your fork push to your branch
14-
4. Test your changes with `pytest`
15-
5. Make a PR
16-
175
## Bug Reports
186

19-
TBD.
7+
Please open an issue.
208

219
## Installing the development environment
2210

2311
```
2412
python -m pip install --upgrade --editable ".[all]"
2513
```
2614

27-
<!-- To make the PR process much smoother we also strongly recommend that you setup the Git pre-commit hook for [Black](https://github.com/psf/black) by running
15+
Also conveniently accessible as `bash install.sh`.
2816

29-
```
30-
pre-commit install
31-
```
17+
## Pull Requests
3218

33-
This will run `black` over your code each time you attempt to make a commit and warn you if there is an error, canceling the commit. -->
19+
### Pull Requests Procedure
3420

35-
## Running the tests
21+
If you would like to make a pull request please:
22+
23+
1. Make a fork of the project
24+
2. Clone your fork locally
25+
3. Install `pre-commit` and the project's `pre-commit` hooks
26+
4. Test your changes with `pytest`
27+
5. Commit your changes to a feature branch of your fork, push to your branch
28+
6. Make a PR
29+
30+
### Running the tests
3631

3732
You can run the unit tests (which should be fast!) via the following command.
3833

3934
```bash
4035
pytest --mpl --ignore=tests/test_notebooks.py
4136
```
4237

43-
Note: This ignores the notebook tests (which are run via [papermill](https://github.com/nteract/papermill) which run somewhat slow.
38+
Note: This ignores the notebook tests (which are run via [papermill](https://github.com/nteract/papermill) and run somewhat slow.
4439
Make sure to run the complete suite before submitting a PR
4540

4641
```bash
4742
pytest --mpl
4843
```
4944

50-
## Making a pull request
45+
### Making a pull request
5146

52-
We try to follow [Conventional Commit](https://www.conventionalcommits.org/) for commit messages and PR titles. Since we merge PR's using squash commits, it's fine if the final commit messages (proposed in the PR body) follow this convention.
47+
We follow [Conventional Commit](https://www.conventionalcommits.org/) for commit messages and PR titles. Since we merge PR's using squash commits, it's fine if the final commit messages (proposed in the PR body) follow this convention.
5348

54-
## Generating Reference Visuals
49+
### Generating Reference Visuals
5550

56-
If you modified expected outcomes of the test. New baseline visuals can be generated using this command:
51+
If you modified expected outcomes of the tests. New baseline visuals can be generated using this command:
5752

5853
```bash
5954
pytest --mpl-generate-path=tests/baseline
6055
```
56+
57+
Only include the actually modified baseline images in your PR! Running `git add -a` and the like will sometimes result in including images which are visually identially but not the same bit-wise.

install.sh

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
python -m pip install --upgrade --editable ".[all]"

0 commit comments

Comments
 (0)