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.4.tar.gz
(2.9 kB
view hashes)
Built Distribution
Close
Hashes for python_githooks-1.0.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f0475c3f2b00dddda0ad38a3a09a4102c709b608c19761f5c61df60d48a09ae0 |
|
MD5 | 2c05761010002c8f50dc09a922a81461 |
|
BLAKE2b-256 | 34349401f2234f5b4b2d87b0b013c0fa2fd4f6af97832937d0495ea726e740d4 |