Hacker News new | ask | show | jobs
by TeMPOraL 1250 days ago
> Ideally we want to describe why we've changed it but this information isn't always available

I struggle to imagine situation in which this is the case. Surely, even in the worst case of you being told to make a particular change with no explanation given, you can at least drop a "increased from 5 at a request of ${name of your boss}", or "increased from 5, see ticket #${ticket number}" in a comment, and/or a commit message.

1 comments

Something that's standard at the company I work for is commit messages always having the ticket number at the start, and it helps figure out why something was changed so much more than a commit message.

Ex of a recent change I saw, but anonymized a bit.

PROJ-12345: Added preview flag to video player

PROJ-12345 in Jira:

When a preview of a video is playing in the persistent player, preroll ads will display on app launch.

A more standardized format is:

  Bug: #12345
if you want to merely reference a specific bug/issue, or

  Closes: #12345
if this commit fixes the bug/closes the issue.

See https://git.wiki.kernel.org/index.php/CommitMessageConventio...

But the PROJ-12345 at the beginning of the first line of the commit is very common in many entreprise projects.