A commitizen plugin that combines gitmoji and conventional commits in a lightweight way.
Project description
cz-conventional-gitmoji
A commitizen plugin that combines gitmoji and conventional commits in a lightweight way.
This fork of cz-conventional-gitmoji adds a simple-types and conventional option to the template.
We will only have the emojis that are related to the cz_conventional_commits types and they will be added to <subject> section of the commit message.
init: 🎉 initial version
Installation
With pip or any other package manager of your choice, the usual way:
pip install cz-light-conventional-gitmoji
Usage
This package can be used as a normal commitizen plugin, either by specifying the name on the command line
cz --name cz_light_gitmoji commit
or by setting it in your pyproject.toml
[tool.commitizen]
name = "cz_light_gitmoji"
This will make commitizen use the commit message parsing rules defined by this plugin, which are 100% compatible with conventional commits. As such, the gitmojis are completely optional and all commands will continue to validate commit messages in conventional format just fine. This is useful if you're transitioning an existing repo to cz-light-conventional-gitmoji or you work in a team in which some colleagues don't like gitmojis.
gitmojify
Apart from the conventional-gitmoji rules, this package provides the gitmojify command which is also available as a pre-commit hook. The command reads a commit message either from cli or a commit message file and prepends the correct gitmoji based on the type. If the message already has a gitmoji, it is returned as is.
$ gitmojify -m "init: initial version"
🎉 init: initial version
To use it as a pre-commit hook, install this packages as well as commitizen and put the following into your .pre-commit-config.yaml
repos:
- repo: https://github.com/sasirven/cz-light-conventional-gitmoji
rev: 0.2.4
hooks:
- id: conventional-gitmoji
Make sure to install the relevant pre-commit hooks with
pre-commit install --install-hooks
Commit with a message in conventional format that contains a valid type mapped by conventional gitmoji and the gitmoji will automagically be added.
Features
- Enable conventional gitmoji commit messages via
cz commit. - Add hook to automatically prepend the appropriate gitmoji for the commit's type.
Inspiration
cz-conventional-gitmoji(Forked from)
Author
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file cz_light_conventional_gitmoji-0.5.0.tar.gz.
File metadata
- Download URL: cz_light_conventional_gitmoji-0.5.0.tar.gz
- Upload date:
- Size: 76.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bc1416b0f5bb84e46c11c455da7605951805a7d2e7ed182633390d1f2bd8d2bc
|
|
| MD5 |
30b66bfec5fa5cbe8fdc105a5d6b900c
|
|
| BLAKE2b-256 |
629ae912b1d49d4ec493475263f185ef065b151192ca66e69eac18ce2366960e
|
File details
Details for the file cz_light_conventional_gitmoji-0.5.0-py3-none-any.whl.
File metadata
- Download URL: cz_light_conventional_gitmoji-0.5.0-py3-none-any.whl
- Upload date:
- Size: 11.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ed9724933fc724580ebe8e31c2ab507f3c50a87e39809a3bbbd71d1212e0c683
|
|
| MD5 |
cc432a57cbd2081fe2317409a64e72be
|
|
| BLAKE2b-256 |
af1b9a2a0c70aa7c883a1e96e716ceacb42dc2672a08c2328d29849999bfa274
|