Search code examples
gitintellij-idea

IntelliJ git commit message template


Is there any way to set default Git commit message or commit message template in IntelliJ? For example I would like that every commit message will look like:

  1. Commit subject:
  2. Feature:
  3. Reviewer:

Solution

  • Ensure JetBrains products version is 2021.1 and later, and then execute under the project directory.

    git config --local commit.template ~/.gitcommit
    

    Remember edit your tempalte in ~/.gitcommit ahead.