Yesterday, I wrote about how much I loved working with the team at Cloud Four on a recent project.
One of the things they do very well that most dev teams I’ve worked with do not is make full use of GitHub’s PR Templates feature.
In my consulting work, I see a lot of PRs that include either a one-line comment or not description at all.
But Cloud Four’s PRs always include a rich amount of detail that makes it much easier for the reviewer to understand what’s going on and what to look at.
honestly, i hate having a form for my coworkers to fill out. i’ve done it before. i’ve seen it done. i prefer my collaborators, especially in a work environment to do the professional thing and give me enough context to understand the change. i don’t want to have to treat my coworkers like half interested children, but that temptation is always there. a bunch of “did you do your homework?” check boxes feels condescending by proxy. we don’t need a check box for “are the tests passing?” cuz we have automated tests and CI.
i prefer something that just nudges people in the right direction if i can get away with it.
just this week i added a template that read like:
PR guidelines are in CONTRIBUTING.md This text is meant to be replaced by a short description of your change to inform as to _why_ this change was made to help us triage errors when things go wrong, to provide relevant context to reviewers, and as a matter of due diligence.You aren’t treating them like children. That’s just projection because you know what you want from a PR and feel like someone telling you what they want is belittling you. Not everybody wants the same nor has the same expectations from a PR.
Guidelines and rules exist for this very reason: people are different. Adding a CONTRIBUTING.md isn’t treating somebody like a child and PR templates neither.
the CONTRIBUTING.md document has always existed and contains our guidelines. they know what we’ve agreed upon belongs in a PR, and they simply don’t do it. i’d rather have an empty description than a big stupid ignored form template, because the problem isn’t they don’t know but that they don’t care. that’s a problem that forms, in my experience, don’t fix.
@chrash0 @onlinepersona That’s a thing I got told back in university: Technology cannot solve social problems (which is quite frustrating, at least in this case…)
If your colleagues cannot follow guidelines, do not have the common sense to add a description, and completely ignore a form, I think you have a much bigger problem on your hands.
I know what you mean. Quite often when I’ve worked in a project where there is a pull request template, a lot of the time people don’t bother to fill it out. However, in an ideal world, people would be proud of the work that they’ve delivered, and take the time to describe the changes when raising a pull request.