Skip to content

Commit ad5972d

Browse files
committed
Add flake8 and pydocstyle to precommit
1 parent 83ee6e8 commit ad5972d

File tree

3 files changed

+11
-2
lines changed

3 files changed

+11
-2
lines changed

.github/workflows/deploy-pypi.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727
- name: Test with pytest
2828
run: |
2929
flake8
30-
pydocstyle
30+
pydocstyle hiclass tests
3131
pytest -v --cov=hiclass --cov-fail-under=90 --cov-report html
3232
coverage xml
3333
- name: Upload Coverage to Codecov

.pre-commit-config.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,12 @@ repos:
99
rev: 24.2.0
1010
hooks:
1111
- id: black
12+
- repo: https://github.com/pycqa/flake8
13+
rev: 7.1.1
14+
hooks:
15+
- id: flake8
16+
- repo: https://github.com/pycqa/pydocstyle
17+
rev: 6.3.0
18+
hooks:
19+
- id: pydocstyle
20+
files: ^hiclass/

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ pip install -e ".[dev]"
1919
To run the tests simply execute:
2020

2121
```
22-
pytest -v --flake8 --pydocstyle --cov=hiclass --cov-fail-under=90 --cov-report html
22+
pytest -v --cov=hiclass --cov-fail-under=90 --cov-report html
2323
```
2424

2525
Lastly, you can set up the git hooks scripts to fix formatting errors locally during commits:

0 commit comments

Comments
 (0)