Perhaps you want every commit to include a Co-authored-by: trailer. Your commit-msg hook could append it automatically:
git commit --no-verify -m "Hotfix for production" COMMIT-EDITMSG
Next time you stage a change, resist the urge to type git commit -m "updates" . Instead, type git commit . Stare at the .git/COMMIT_EDITMSG file. Write a story. Automate the boring parts. Your future self—and your teammates—will thank you. Perhaps you want every commit to include a
git config --global commit.template ~/.gitmessage.txt the COMMIT_EDITMSG file is the battleground.
If you use Git hooks (like commit-msg or pre-commit ), the COMMIT_EDITMSG file is the battleground.