4 ms·
Honestly, I think better rules are: - Whenever someone asks a question in a pull request, answer it by putting a comment in code. - Include a ticket number (fo
by gwbas1c 7y ago
Honestly, I think better rules are:
- Whenever someone asks a question in a pull request, answer it by putting a comment in code.
- Include a ticket number (for whatever ticketing system you use) in the commit
Why? I find that commit messages are black boxes. They only come out when doing a git blame, but they don't show up in my IDE. Instead, I'm more likely to run across messages like this when they're comments in code or discussions in our ticketing system.
I think if we had tighter integration among our IDE, git, and the ticketing system, detailed messages commit messages like this would be extremely useful.
- adwww 7y agoCode comments have a habbit of getting lost during future tidy ups or refactors. If the code is that unclear it needs a comment, refactor it into a named method, where the method name describes exactly what it's doing.