Create git hooks with ease using a simple configuration file in a git project
Project description
python-githooks
Create git hooks with ease using a simple configuration file in a git project
Install
pip install python-githooks
Usage
- Create a
.githooks.ini
configuration file(If not provided a dummy configuration file will be created). - Add sections based on
git hooks names
followed by acommand
property with the shell code you want to run. - Run either
python -m python_githooks
orgithooks
in you virtual environment.
- Configuration file Example:
[pre-commit]
command = pytest --cov
[pre-push]
command = pytest --cov && flake8
License
python-githooks is MIT-licensed.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
python-githooks-1.0.1.tar.gz
(2.7 kB
view hashes)
Built Distribution
Close
Hashes for python_githooks-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2fcb550b1417c7d7fc9a4a0e084ee08ae5d8d8d54ff16951ce081a3cefbf8036 |
|
MD5 | b99bb80fa415b83ed1508449d18d2fc1 |
|
BLAKE2b-256 | deafa5caa7bdf2df559d1210621bcb192663861e50c1289adeed93f2b3f68981 |