8000 Update contribution notes with 'modern' way of installing with pip in… · realpython/codetiming@0ebf506 · GitHub
[go: up one dir, main page]

Skip to content

Commit 0ebf506

Browse files
authored
Update contribution notes with 'modern' way of installing with pip instead of flit (#49)
1 parent a126197 commit 0ebf506

File tree

1 file changed

+9
-13
lines changed

1 file changed

+9
-13
lines changed

CONTRIBUTING.md

Lines changed: 9 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -26,24 +26,20 @@ Do you want to contribute code to `codetiming`? Fantastic! We welcome contributi
2626

2727
## Setting Up Your Environment
2828

29-
`codetiming` uses [`flit`](https://flit.readthedocs.io) for package management. You should first install `flit`:
29+
`codetiming` uses [`flit`](https://flit.readthedocs.io) for package management. You can use `flit` through [`pip`](https://realpython.com/what-is-pip/).
3030

31-
```
32-
$ python -m pip install flit
33-
```
34-
35-
You can then install `codetiming` locally for development with `flit`:
31+
You can then install `codetiming` locally for development with `pip`:
3632

3733
```
38-
$ python -m flit install --pth-file --deps all
34+
$ python -m pip install --editable .[dev,test]
3935
```
4036

41-
This will install `codetiming` and all its dependencies, including development tools like [`black`](https://black.readthedocs.io) and [`mypy`](http://mypy-lang.org/). The `--pth-file` option allows you to test your changes without reinstalling. On Linux and Mac, you can use `--symlink` for the same effect.
37+
This will install `codetiming` and all its dependencies, including development tools like [`black`](https://black.readthedocs.io) and [`mypy`](http://mypy-lang.org/), and test runners like [`pytest`](https://docs.pytest.org/). The `--editable` option allows you to test your changes without reinstalling.
4238

4339

4440
## Running Tests
4541

46-
Run tests using [`tox`](https://tox.readthedocs.io/). `tox` helps to enforce the following principles:
42+
Run tests using [`tox`](https://tox.readthedocs.io/). You can also run individual tests manually. `tox` helps to enforce the following principles:
4743

4844
- Consistent code style using [`black`](https://black.readthedocs.io). You can automatically format your code as follows:
4945

@@ -62,10 +58,10 @@ Run tests using [`tox`](https://tox.readthedocs.io/). `tox` helps to enforce the
6258
- Unit testing using [`pytest`](https://docs.pytest.org/). You can run your tests and see a coverage report as follows:
6359

6460
```console
65-
$ pytest --cov=codetiming --cov-report=term-missing
61+
$ python -m pytest --cov=codetiming --cov-report=term-missing
6662
```
6763

68-
- Code issues are checked with the [flake8]() linter. You can run flake8 manually as follows:
64+
- Code issues are checked with the [flake8](https://flake8.pycqa.org/) linter. You can run flake8 manually as follows:
6965

7066
```console
7167
$ python -m flake8 codetiming/ tests/
@@ -80,7 +76,7 @@ Run tests using [`tox`](https://tox.readthedocs.io/). `tox` helps to enforce the
8076
- All modules, functions, classes, and methods must have docstrings. This is enforced by [Interrogation](https://interrogate.readthedocs.io/). You can test compliance as follows:
8177

8278
```console
83-
$ interrogate -c pyproject.toml -vv
79+
$ python -m interrogate -c pyproject.toml -vv
8480
```
8581

86-
Feel free to ask for help in your PR if you are having challenges with any of these tests.
82+
Feel free to ask for help in your PR if you are having challenges with any of these tests.

0 commit comments

Comments
 (0)
0