# π Conventional Commits Check
![PyPI Version](https://img.shields.io/pypi/v/conventional-commits-check)
![License](https://img.shields.io/github/license/AliYmn/conventional-commits-check)
![Last Commit](https://img.shields.io/github/last-commit/AliYmn/conventional-commits-check)
![Issues](https://img.shields.io/github/issues/AliYmn/conventional-commits-check)
![Stars](https://img.shields.io/github/stars/AliYmn/conventional-commits-check?style=social)
![Forks](https://img.shields.io/github/forks/AliYmn/conventional-commits-check?style=social)
![Downloads](https://img.shields.io/pypi/dm/conventional-commits-check)
![Contributors](https://img.shields.io/github/contributors/AliYmn/conventional-commits-check)
![Result Image](https://raw.githubusercontent.com/AliYmn/conventional-commits-check/master/images/result.png)
`conventional-commits-check` is a powerful and easy-to-use Python pre-commit hook that helps enforce [Conventional Commits](https://www.conventionalcommits.org/) rules on your commit messages. It supports adding relevant emojis based on your commit types to enhance readability and bring some fun to your commit history! π
## π What are Conventional Commits?
Conventional Commits provide a lightweight convention for creating a clear and explicit commit history. By using this hook, you'll ensure that your commit messages follow this convention, making your versioning easier to manage and your collaboration more seamless.
## π‘ Features
- β
Enforces Conventional Commits rules on your commit messages.
- π¨ Optionally adds context-specific emojis to the start of commit messages.
- π Blocks commits that do not conform to the Conventional Commits standard.
- π§ Allows for **custom commit types** and **custom emojis** via configuration.
## π§ Customization
You can customize the commit types and their associated emojis by modifying the `commit_types.yml` and `commits_check_config.yaml` files. These files allow you to define additional commit types and specify emojis for each type.
### Example : [`commit_types.py`](https://github.com/AliYmn/conventional-commits-check/blob/master/conventional_commits_check/commit_types.py)
```python
commit_types:
{
"access": {
"description": "Improve accessibility.",
"emoji": "βΏοΈ"
},
"analytics": {
"description": "Add or update analytics or track code.",
"emoji": "π"
},
"animation": {
"description": "Add or update animations and transitions.",
"emoji": "π«"
},
"arch": {
"description": "Make architectural changes.",
"emoji": "ποΈ"
},
"assets": {
"description": "Add or update assets.",
"emoji": "π±"
},
"beer": {
"description": "Write code drunkenly.",
"emoji": "π»"
},
.....
```
### Customizing Existing Emojis
You can also modify the emojis for existing commit types by updating the `commits_check_config.yaml`:
```yaml
additional_commit_types:
feat:
description: Introduce new features.
emoji: π
fix:
description: Fix a bug.
emoji: π οΈ
```
## βοΈ Installation
To add `conventional-commits-check` to your project, follow these steps:
1. **Update your `.pre-commit-config.yaml`:**
In your projectβs root directory, add the following:
```yaml
repos:
- repo: https://github.com/AliYmn/conventional-commits-check
rev: v0.3.0 # Use the latest release version
hooks:
- id: conventional-commits-check
stages: [commit-msg]
args: ["--emoji-disabled"] # Use this argument to disable emojis
```
2. **Install the pre-commit hook:**
```bash
pre-commit install --hook-type commit-msg -f
```
3. **Install the `conventional-commits-check` package:**
```bash
pip install -U conventional-commits-check
```
4. **Optional:** Update the pre-commit package:
```bash
pre-commit autoupdate
```
## π Usage
Once the hook is added, it will automatically run each time you make a commit. The hook checks your commit message against Conventional Commits rules, optionally adds the appropriate emoji, and prevents non-conforming commits.
## π¨βπ» Contributing
Contributions are welcome! Feel free to open issues or submit pull requests to enhance `conventional-commits-check`. Letβs make commits fun and consistent! π
## π License
This project is licensed under the [MIT License](LICENSE).
---
Enhance your workflow and bring some life to your commits with `conventional-commits-check`! πβ¨π
Raw data
{
"_id": null,
"home_page": "https://github.com/AliYmn/conventional-commits-check",
"name": "conventional-commits-check",
"maintainer": null,
"docs_url": null,
"requires_python": null,
"maintainer_email": null,
"keywords": null,
"author": "Ali Yaman",
"author_email": null,
"download_url": "https://files.pythonhosted.org/packages/d8/58/86b1b294b7a419a7b42c9c4a7910f3d0ac7c6a966b94b55f0c1b3f9a94c1/conventional_commits_check-2.3.0.tar.gz",
"platform": null,
"description": "# \ud83c\udf89 Conventional Commits Check\n\n![PyPI Version](https://img.shields.io/pypi/v/conventional-commits-check)\n![License](https://img.shields.io/github/license/AliYmn/conventional-commits-check)\n![Last Commit](https://img.shields.io/github/last-commit/AliYmn/conventional-commits-check)\n![Issues](https://img.shields.io/github/issues/AliYmn/conventional-commits-check)\n![Stars](https://img.shields.io/github/stars/AliYmn/conventional-commits-check?style=social)\n![Forks](https://img.shields.io/github/forks/AliYmn/conventional-commits-check?style=social)\n![Downloads](https://img.shields.io/pypi/dm/conventional-commits-check)\n![Contributors](https://img.shields.io/github/contributors/AliYmn/conventional-commits-check)\n\n![Result Image](https://raw.githubusercontent.com/AliYmn/conventional-commits-check/master/images/result.png)\n\n`conventional-commits-check` is a powerful and easy-to-use Python pre-commit hook that helps enforce [Conventional Commits](https://www.conventionalcommits.org/) rules on your commit messages. It supports adding relevant emojis based on your commit types to enhance readability and bring some fun to your commit history! \ud83d\ude80\n\n## \ud83d\udcdc What are Conventional Commits?\n\nConventional Commits provide a lightweight convention for creating a clear and explicit commit history. By using this hook, you'll ensure that your commit messages follow this convention, making your versioning easier to manage and your collaboration more seamless.\n\n## \ud83d\udca1 Features\n\n- \u2705 Enforces Conventional Commits rules on your commit messages.\n- \ud83c\udfa8 Optionally adds context-specific emojis to the start of commit messages.\n- \ud83d\uded1 Blocks commits that do not conform to the Conventional Commits standard.\n- \ud83d\udd27 Allows for **custom commit types** and **custom emojis** via configuration.\n\n## \ud83d\udd27 Customization\n\nYou can customize the commit types and their associated emojis by modifying the `commit_types.yml` and `commits_check_config.yaml` files. These files allow you to define additional commit types and specify emojis for each type.\n\n### Example : [`commit_types.py`](https://github.com/AliYmn/conventional-commits-check/blob/master/conventional_commits_check/commit_types.py)\n\n```python\ncommit_types:\n {\n \"access\": {\n \"description\": \"Improve accessibility.\",\n \"emoji\": \"\u267f\ufe0f\"\n },\n \"analytics\": {\n \"description\": \"Add or update analytics or track code.\",\n \"emoji\": \"\ud83d\udcc8\"\n },\n \"animation\": {\n \"description\": \"Add or update animations and transitions.\",\n \"emoji\": \"\ud83d\udcab\"\n },\n \"arch\": {\n \"description\": \"Make architectural changes.\",\n \"emoji\": \"\ud83c\udfd7\ufe0f\"\n },\n \"assets\": {\n \"description\": \"Add or update assets.\",\n \"emoji\": \"\ud83c\udf71\"\n },\n \"beer\": {\n \"description\": \"Write code drunkenly.\",\n \"emoji\": \"\ud83c\udf7b\"\n },\n .....\n```\n\n### Customizing Existing Emojis\n\nYou can also modify the emojis for existing commit types by updating the `commits_check_config.yaml`:\n\n```yaml\nadditional_commit_types:\n feat:\n description: Introduce new features.\n emoji: \ud83c\udf89\n fix:\n description: Fix a bug.\n emoji: \ud83d\udee0\ufe0f\n```\n\n## \u2699\ufe0f Installation\n\nTo add `conventional-commits-check` to your project, follow these steps:\n\n1. **Update your `.pre-commit-config.yaml`:**\n\n In your project\u2019s root directory, add the following:\n\n ```yaml\n repos:\n - repo: https://github.com/AliYmn/conventional-commits-check\n rev: v0.3.0 # Use the latest release version\n hooks:\n - id: conventional-commits-check\n stages: [commit-msg]\n args: [\"--emoji-disabled\"] # Use this argument to disable emojis\n ```\n\n2. **Install the pre-commit hook:**\n\n ```bash\n pre-commit install --hook-type commit-msg -f\n ```\n\n3. **Install the `conventional-commits-check` package:**\n\n ```bash\n pip install -U conventional-commits-check\n ```\n\n4. **Optional:** Update the pre-commit package:\n\n ```bash\n pre-commit autoupdate\n ```\n\n## \ud83d\ude80 Usage\n\nOnce the hook is added, it will automatically run each time you make a commit. The hook checks your commit message against Conventional Commits rules, optionally adds the appropriate emoji, and prevents non-conforming commits.\n\n## \ud83d\udc68\u200d\ud83d\udcbb Contributing\n\nContributions are welcome! Feel free to open issues or submit pull requests to enhance `conventional-commits-check`. Let\u2019s make commits fun and consistent! \ud83d\ude04\n\n## \ud83d\udcdc License\n\nThis project is licensed under the [MIT License](LICENSE).\n\n---\n\nEnhance your workflow and bring some life to your commits with `conventional-commits-check`! \ud83c\udf89\u2728\ud83d\udc1b\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "A pre-commit hook to check Conventional Commits and add emojis.",
"version": "2.3.0",
"project_urls": {
"Homepage": "https://github.com/AliYmn/conventional-commits-check"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "88a1fa9ebfcd6c3a8a1311e80205242a8798009ecaf86ac3ad73730e999eb3c9",
"md5": "70b64ec39a1670ba2297562a621ba0b2",
"sha256": "51ebc4645ce298a86189f3c14a833d97e166475dfffc194ebb0b81ace8f20d1e"
},
"downloads": -1,
"filename": "conventional_commits_check-2.3.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "70b64ec39a1670ba2297562a621ba0b2",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 9017,
"upload_time": "2024-10-28T21:38:28",
"upload_time_iso_8601": "2024-10-28T21:38:28.614547Z",
"url": "https://files.pythonhosted.org/packages/88/a1/fa9ebfcd6c3a8a1311e80205242a8798009ecaf86ac3ad73730e999eb3c9/conventional_commits_check-2.3.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "d85886b1b294b7a419a7b42c9c4a7910f3d0ac7c6a966b94b55f0c1b3f9a94c1",
"md5": "37b682062438d296ededea362d3cebf8",
"sha256": "f7af0e543385b9193836e1a56a6b171286774ca3d1bbf737dffc2c9628f072f1"
},
"downloads": -1,
"filename": "conventional_commits_check-2.3.0.tar.gz",
"has_sig": false,
"md5_digest": "37b682062438d296ededea362d3cebf8",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 7881,
"upload_time": "2024-10-28T21:38:30",
"upload_time_iso_8601": "2024-10-28T21:38:30.009233Z",
"url": "https://files.pythonhosted.org/packages/d8/58/86b1b294b7a419a7b42c9c4a7910f3d0ac7c6a966b94b55f0c1b3f9a94c1/conventional_commits_check-2.3.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-10-28 21:38:30",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "AliYmn",
"github_project": "conventional-commits-check",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "conventional-commits-check"
}