diff --git a/README.md b/README.md index c4b3a405..75c76aff 100644 --- a/README.md +++ b/README.md @@ -95,6 +95,16 @@ follow these steps: It will run on every commit automatically. +### pre-commit Configuration + +A `.pre-commit-config.yaml` file has been added to the repository. This configuration file defines hooks to maintain code quality and formatting standards. These hooks are automatically executed before each commit to ensure consistency across the codebase. They include: + +- **Black**: A code formatter for Python. +- **Flake8**: A tool that checks Python code for style and quality. +- **isort**: A utility for sorting and formatting Python imports. + +The configuration ensures that the codebase adheres to consistent formatting and style guidelines, enhancing readability and maintainability. + #### Using [`dev/tools.sh`][tools-sh] helper script The [`dev/tools.sh`][tools-sh] helper script runs the static analysis tools (`black`, `flake8`, and `isort`): @@ -126,7 +136,7 @@ directories to check: [ccospyguide]: https://opensource.creativecommons.org/contributing-code/python-guidelines/ [black]: https://github.com/psf/black -[flake8]: https://gitlab.com/pycqa/flake8 +[flake8]: https://github.com/PyCQA/flake8 [isort]: https://pycqa.github.io/isort/ [pipenv]: https://github.com/pypa/pipenv [pre-commit]: https://pre-commit.com/ @@ -174,7 +184,6 @@ The data within this repository is dedicated to the public domain under the [cc-zero-png]: https://licensebuttons.net/l/zero/1.0/88x31.png "CC0 1.0 Universal (CC0 1.0) Public Domain Dedication button" [cc-zero]: https://creativecommons.org/publicdomain/zero/1.0/ - ### Documentation [![CC BY 4.0 license button][cc-by-png]][cc-by]