giticket
========
.. image:: https://img.shields.io/pypi/v/giticket.svg
:target: https://pypi.python.org/pypi/giticket
.. image:: https://travis-ci.com/milin/giticket.svg?branch=master
:target: https://travis-ci.org/milin/giticket
.. image:: https://readthedocs.org/projects/giticket/badge/?version=latest
:target: https://giticket.readthedocs.io/en/latest/?badge=latest
:alt: Documentation Status
Auto add ticket info to your git commits.
* Free software: MIT license
* Documentation: https://giticket.readthedocs.io.
Features
--------
This hook saves developers time by prepending ticket numbers to commit-msgs.
For this to work the following two conditions must be met:
- The ticket format regex specified must match, if the regex is passed in.
- The branch name format must be <ticket number>_<rest of the branch name>
For e.g. if you name your branch ``JIRA-1234_awesome_feature`` and commit ``Fix some bug``, the commit will be updated to ``JIRA-1234 Fix some bug``.
Pass ``--regex=`` or update ``args: [--regex=<custom regex>]`` in your .yaml file if you have custom ticket regex.
By default it's ``[A-Z]+-\d+``.
Pass ``--format=`` or update ``args: [--format=<custom template string>]`` in your .yaml file if you have custom message replacement.
By default it's ``'{ticket} {commit_msg}``, where ``ticket`` is replaced with the found ticket number and ``commit_msg`` is replaced with the original commit message.
It is best used along with pre-commit_. You can use it along with pre-commit by adding the following hook in your ``.pre-commit-config.yaml`` file.
::
repos:
- repo: https://github.com/milin/giticket
rev: 'e0bf7ae'
hooks:
- id: giticket
args: ['--regex=PROJ-[0-9]', --format='"{ticket} {commit-msg}"'] # Optional
You need to have precommit setup to use this hook.
--------------------------------------------------
Install Pre-commit and the commit-msg hook-type.
::
pip install pre-commit==1.11.1
pre-commit install
pre-commit install --hook-type commit-msg
.. _pre-commit: https://pre-commit.com/
=======
History
=======
0.1.5 (2019-04-23)
------------------
* Add custom commit message template to be passed in.
0.1.0 (2019-01-02)
------------------
* First release on PyPI.
Metadata
Release files for giticket 0.1.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| giticket-0.1.5.tar.gz | 11.0 kB | Without provenance | Details for giticket-0.1.5.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| giticket-0.1.5-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details for giticket-0.1.5-py2.py3-none-any.whl |
Total release size: 15.8 kB
Release files / giticket-0.1.5.tar.gz
| Download URL | giticket-0.1.5.tar.gz |
|---|---|
| Size | 11.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e2badd6c3ffa8df90b802e925c0a7f91c5cb94566168d1ce6d2ef5193dbbcd0e
|
|
BLAKE2b-256 checksum How to use checksums |
9e6fba7a9edacfa651798c98e87a4a732c588bd30feeb876de7ecbdb5e897b19
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.26.0 CPython/3.7.0
|
Release files / giticket-0.1.5-py2.py3-none-any.whl
| Download URL | giticket-0.1.5-py2.py3-none-any.whl |
|---|---|
| Size | 4.8 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
42d0f3a57139bcf3335252728d2987f2db589e3670d4a754a1793d3db5f2a7c4
|
|
BLAKE2b-256 checksum How to use checksums |
f3ed74ef117e33abd885f1d1405bb69c1d4a5dc3f5685de7a7b52dcc9392881c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.26.0 CPython/3.7.0
|
Security for giticket 0.1.5
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.