https://github.com/tjoskar/gitmoji-commit-hook
Start the commit message with an applicable emoji
https://github.com/tjoskar/gitmoji-commit-hook
emoji git-hooks
Last synced: 10 months ago
JSON representation
Start the commit message with an applicable emoji
- Host: GitHub
- URL: https://github.com/tjoskar/gitmoji-commit-hook
- Owner: tjoskar
- License: mit
- Created: 2015-12-04T18:20:50.000Z (about 10 years ago)
- Default Branch: main
- Last Pushed: 2025-04-03T23:11:34.000Z (10 months ago)
- Last Synced: 2025-04-05T15:01:52.869Z (10 months ago)
- Topics: emoji, git-hooks
- Language: JavaScript
- Size: 3.25 MB
- Stars: 69
- Watchers: 2
- Forks: 9
- Open Issues: 11
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Gitmoji-commit-hook
[](https://actions-badge.atrox.dev/tjoskar/gitmoji-commit-hook/goto)
> Prepend the right emoji to your commit message from [Gitmoji](https://github.com/carloscuesta/gitmoji)
## Install
- Install gitmoji-commit-hook package
```
$ npm install -g gitmoji-commit-hook
```
- Install the hook
```
$ cd any-git-initialized-directory
$ gitmoji-commit-hook --init
```
## Usage

## Config
You can put unwanted emojis in a blacklist section by adding the name in a blacklist array in your `package.json`:
```json
{
"gitmoji": {
"blacklist": [
"card-file-box",
"beers"
]
}
}
```
## Emoji Meanings
A list of available emojis and their associated meanings can be found at [gitmoji.carloscuesta.me](https://gitmoji.carloscuesta.me/)
## KISS principle
This package follow KISS principle, the only thing it does is to allow you
to add an emoji from gitmojis list to your commit.
If you're looking for some other cool feature like search in gitmojis list,
please consider [gitmoji-cli](https://github.com/carloscuesta/gitmoji-cli)
## Develop
To run the linter: `npm run lint`
To run the unit test: `npm test`
To dry run the script:
```bash
node invoke.js --init # run the init setup
node invoke.js mock_hooks/COMMIT_EDITMSG # simulate a git commit
```
## License
The code is available under the [MIT](https://github.com/tjoskar/gitmoji-commit-hook/blob/master/LICENSE) license.