Forked from adeekshith/.git-commit-template.txt
Last active
February 20, 2020 00:01
-
-
Save WesleyGoncalves/c4d6799f26931e478e1b74a05c7f0a5a to your computer and use it in GitHub Desktop.
This commit message template helps you write great commit messages and enforce it across teams.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# <type>[(optional scope)]: (If applied, this commit will...) <subject> (Max 50 char) | |
# |<---- Using a Maximum Of 50 Characters ---->| | |
# Explain why this change is being made | |
# |<---- Try To Limit Each Line to a Maximum Of 72 Characters ---->| | |
# Provide links or keys to any relevant tickets, articles or other resources | |
# Example: Github issue #23 | |
# --- COMMIT END --- | |
# Type can be | |
# feat (new feature) | |
# fix (bug fix) | |
# refactor (refactoring production code) | |
# style (formatting, missing semi colons, etc; no code change) | |
# deprecate (a special case of documentation. You should use it when some resource/code *become deprecated* - added so changelog generators can create a section for these changes as suggested by https://keepachangelog.com/en/1.0.0/#how) | |
# remove (a special case of documentation. You should use it when some (deprecated or not) resource/code *is removed* - added so changelog generators can create a section for these changes as suggested by https://keepachangelog.com/en/1.0.0/#how) | |
# docs (changes to documentation) | |
# test (adding or refactoring tests; no production code change) | |
# chore (updating grunt tasks etc; no production code change) | |
# -------------------- | |
# Remember to | |
# Capitalize the subject line | |
# Use the imperative mood in the subject line | |
# Do not end the subject line with a period | |
# Separate subject from body with a blank line | |
# Separate body from footer with a blank line | |
# Use the body to explain what and why vs. how | |
# Can use multiple lines with(out) "-" in body | |
# -------------------- | |
# For more information about this template, check out | |
# https://gist.github.com/WesleyGoncalves/c4d6799f26931e478e1b74a05c7f0a5a | |
# and the Conventional Commits in https://www.conventionalcommits.org/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
INSTALL GLOBALLY
curl -o ~/.git-commit-template https://gist.githubusercontent.com/WesleyGoncalves/c4d6799f26931e478e1b74a05c7f0a5a/raw/.git-commit-template
git config --global commit.template ~/.git-commit-template
Now every time you run
git commit
the template will be displayed for you in the terminal. Try it.INSTALL LOCALLY (only in one project)
curl -O https://gist.githubusercontent.com/WesleyGoncalves/c4d6799f26931e478e1b74a05c7f0a5a/raw/.git-commit-template
git config commit.template .git-commit-template
Now every time you run
git commit
in this project, the template will be displayed for you in the terminal. Try it.If you prefer, you can ignore this file in the repo using
echo .git-commit-template >> .gitignore
to add to the.gitignore
file.