Skip to content

Commit

Permalink
Merge pull request #204: adds pre-commit
Browse files Browse the repository at this point in the history
  • Loading branch information
pc494 authored Mar 27, 2024
2 parents fae5ca5 + d7811aa commit 80473c8
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 0 deletions.
10 changes: 10 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
repos:
- repo: https://github.com/psf/black
# Version can be updated by running "pre-commit autoupdate"
rev: 24.3.0
hooks:
- id: black
ci:
# Don't run automatically on PRs, instead add the comment
# "pre-commit.ci autofix" on a pull request to manually trigger auto-fixing
autofix_prs: false
1 change: 1 addition & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ Unreleased
Added
-----
- Explicit support for Python 3.11.
- Added Pre-Commit for code formatting.

Changed
-------
Expand Down
4 changes: 4 additions & 0 deletions CONTRIBUTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,10 @@ Please run the latest version of
`black <https://black.readthedocs.io/en/stable/the_black_code_style/index.html>`_ on
your newly added and modified files prior to each PR.

If this doesn't work for you, you can also use the Pre-commit CI to reformat your code
on github by commenting "pre-commit autofix" on your PR.


Run and write tests
-------------------

Expand Down

0 comments on commit 80473c8

Please sign in to comment.