3 ms·
Ask HN: Is there a way to enforce Git merges/commits?
I was curious if there was a way to enforce 2 things on a git repo in either bitbucket or github
1) A JIRA-XXX format at the start of each commit. This makes sure we can relate/find a commit with a ticket/issue/feature and vice versa
2) Require merges to be rebased/squashed
- cimmanom 8y ago(1) at least could probably be done with a hook on commit or push. It’s also not all that difficult to inculcate culturally. Many teams just do this as part of agreed upon process without any explicit enforcement necessary.
- chrisan 8y agoOh we have agreed upon the process certainly... its just that sometimes people get lazy/forgetful and I hate being the git log nazi reviewing code all the time. Oh well. I'll checkout the hook thx