75386[BUGFIX] Abort commit if commit message does not fulfill all requirements
Commit message
Review
-
Code review CR +2 Done
- Christian Kuhn +2
- Nikita Hovratov +1
- André Buchmann +1
-
Verified V +2 Done
- Christian Kuhn +2
- Nikita Hovratov +1
- André Buchmann +1
- core-ci +1 CI
Issues 1
Files 1
Review log 1516
-
Simon Schaufelberger uploaded patch set 1 08/06/22, 00:56
-
Simon Schaufelberger commented on patch set 1 08/06/22, 01:02
If you commit in phpstorm, you will never see the error message that you are missing something which must be avoided. -
core-ci voted on patch set 1 V +1 08/06/22, 01:03 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/29883
-
André Buchmann voted on patch set 1 V +1 CR +1 08/06/22, 07:20
-
Christian Kuhn voted on patch set 1 V +1 CR +1 08/07/22, 15:19
-
Nikita Hovratov voted on patch set 1 V +1 CR +1 08/07/22, 15:24
-
Christian Kuhn voted on patch set 1 V +2 CR +2 08/07/22, 15:24
-
Christian Kuhn merged patch set 2 08/07/22, 15:24
-
Stefan Bürk commented on patch set 2 08/07/22, 17:39
I think it will get really annoying for contributers ... if they write some text in the commit message, but something is missing (or by typo) everything is "lost" and they have to write it again. First commit will of a new patch will leave files "not added" - on a amend the same. -
Simon Schaufelberger commented on patch set 2 08/07/22, 17:42
Reply
Well, on the other hand we had several patches in the past that broke the rules which should not happen as the CI also doesn't check them as you also just aborted your patch a few days ago. -
Stefan Bürk commented on patch set 2 08/07/22, 17:46
Reply
Yeah - but still, I think this would be better suited for a additional pre-push hook to "prevent" pushing. so the message can be simply fixed - instead of redoing the full "commit message". Think about a longer commit message, and a typo in "Resolved" (happens some times) - think about how frustating this may be get for you, and than thing about new contributers. -
Simon Schaufelberger commented on patch set 2 08/07/22, 17:51
Reply
For this reason I use git commit templates: .git/config: [commit] template = /home/simon/.gittypo3message.txt content: [BUGFIX|TASK|FEATURE|DOCS] Resolves: # Releases: main, 11.5 This works also in phpstorm! -
Stefan Bürk commented on patch set 2 08/07/22, 17:55
Reply
Done -
Simon Schaufelberger commented on patch set 2 08/07/22, 17:55
Reply Unresolved
Yeah, but you are right, the commit message is then gone and you have to write it again which is frustrating. If you have a better idea how to make sure the commit fulfulls all requirements, then I'm happy for a good solution. I was hoping that you complete your patch from https://review.typo3.org/c/Packages/TYPO3.CMS/+/75287 -
Christian Kuhn commented on patch set 2 08/12/22, 17:58
ok. the fact that the hook now *throws away* any commit message is really not cool. we should revert this patch. -
Christian Kuhn wrote 08/12/22, 18:04
Created a revert of this change as I87a9ba8d376e800d79c148901401995b1626fc6f