pre-commit
module help you setup git pre-commit hook with a pre-defined configuration .pre-commit-config.yaml
in this repo. Follow instructions below,
> pip install pre-commit flake8
...
> pre-commit --version
pre-commit 2.12.1
> pre-commit install
pre-commit installed at .git/hooks/pre-commit