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.3.tar.gz
(2.9 kB
view hashes)
Built Distribution
Close
Hashes for python_githooks-1.0.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5c73ca9cb590938362e66c802254bfef033451e1d32202f685acc87daafdce74 |
|
MD5 | 9cd17210d5d188576dd4177e77802776 |
|
BLAKE2b-256 | 9d9c3fd3689b272908443964c208f2830f7a36c4021904dfea1a96207935b0cc |