Skip to content

Commit 80473c8

Browse files
authored
Merge pull request #204: adds pre-commit
2 parents fae5ca5 + d7811aa commit 80473c8

File tree

3 files changed

+15
-0
lines changed

3 files changed

+15
-0
lines changed

.pre-commit-config.yaml

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
repos:
2+
- repo: https://github.com/psf/black
3+
# Version can be updated by running "pre-commit autoupdate"
4+
rev: 24.3.0
5+
hooks:
6+
- id: black
7+
ci:
8+
# Don't run automatically on PRs, instead add the comment
9+
# "pre-commit.ci autofix" on a pull request to manually trigger auto-fixing
10+
autofix_prs: false

CHANGELOG.rst

+1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ Unreleased
1313
Added
1414
-----
1515
- Explicit support for Python 3.11.
16+
- Added Pre-Commit for code formatting.
1617

1718
Changed
1819
-------

CONTRIBUTING.rst

+4
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,10 @@ Please run the latest version of
8686
`black <https://black.readthedocs.io/en/stable/the_black_code_style/index.html>`_ on
8787
your newly added and modified files prior to each PR.
8888

89+
If this doesn't work for you, you can also use the Pre-commit CI to reformat your code
90+
on github by commenting "pre-commit autofix" on your PR.
91+
92+
8993
Run and write tests
9094
-------------------
9195

0 commit comments

Comments
 (0)