Skip to content

Commit

Permalink
feat: add pre-commit configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
sanjayankur31 committed Jul 17, 2023
1 parent b384ef6 commit df8619c
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 2 deletions.
13 changes: 13 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-added-large-files
- repo: https://github.com/psf/black
rev: 23.3.0
hooks:
- id: black
12 changes: 10 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,14 @@ pyNeuroML. Pull requests with enhancements and bug fixes are welcome.

## Pull Request Process

1. Please ensure that the automated build for your pull request passes.
2. Please pay attention to the results from flake8 and make any modifications
1. Please contribute pull requests against the `development` branch.
2. Please ensure that the automated build for your pull request passes.
3. Please pay attention to the results from flake8 and make any modifications
to ensure a consistent code style.

## Pre-commit

A number of [pre-commit](https://pre-commit.com/) hooks are used to improve code-quality.
Please run the following code to set up the pre-commit hooks:

$ pre-commit install
1 change: 1 addition & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ dev =
pytest
pytest-cov
kaleido
pre-commit

experimental =
pyNeuroML[dev]
Expand Down

0 comments on commit df8619c

Please sign in to comment.