Comment by teeray

Comment by teeray 4 hours ago

7 replies

> strictly enforces the Conventional Commits specification (feat, fix, chore, etc.).

Nope. Waste of bytes in my commit message header that are better done by git trailers.

Otherwise, I love the idea of the tool. I personally try to answer “why does this commit exist?” when I create commits.

layer8 16 minutes ago

These categories can be useful, as they indicate part of the “why”. I just heavily dislike the value judgement of “chore”.

withinboredom 3 hours ago

I have a coworker that makes every branch into a story about wizards, elfs, or whatever. There's a whole arc that explains the story of the commit in a fun way. I have no idea how he comes up with it all for the past 10 years.

IshKebab 2 hours ago

I agree, I hate conventional commits. Why the hell do I care if changes are chores or features? I want to know what the change was.

  • imiric 2 hours ago

    I'm surprised to read that someone not only finds no value in conventional commits, but actively hates it. Wow.

    A few reasons to care about CCs:

    - The first few characters of a commit message tell you immediately the type of change you should expect. This tells you part of the "what" at a glance. If you're looking for a bug fix, for example, you can safely ignore any other type of commit.

    - Thinking about the type of change you're committing helps you create atomic commits. Anything that is not strictly related should go in a separate commit. Hopefully you already know why you should care about this.

    - A conventional commit message also often includes the change scope. This is a handy way to indicate the subsystem that was changed, which is also useful for filtering, searching, aggregating, etc.

    - They help with writing change logs. I'm a strong proponent of the idea that change logs shouldn't be just autogenerated dumps of commit messages, but carefully redacted for the intended audience, and CCs can help with grouping changes by type or scope. These days LLMs do a decent job at generating this type of changelog (even though it should still be manually reviewed and tweaked), and the additional metadata provided by CCs helps them make it more accurate.

    • zahlman 35 minutes ago

      I'm with Ish on this one.

      > The first few characters of a commit message tell you immediately the type of change you should expect.

      1. Why do I care about this particular classification of "type" of change?

      2. "The first few characters" of the message aren't actually what I necessarily see first, anyway.

      > If you're looking for a bug fix, for example, you can safely ignore any other type of commit.

      1. If I'm looking for a bug fix, I'm using tools like git blame and git bisect.

      2. How often do bugs actually get fixed by a single commit, that has that bug fix as their sole purpose, and which is recognized as a bug fix at the time of writing? I'm guessing it's much lower than one would naively expect.

      3. If I'm looking for a bug fix, I'm looking for the fix for a specific bug, which is probably most recognizable by some bug tracker issue ID. (And if not, it's most searchable that by figuring out an ID and looking that up). So I'm scanning lines for a # symbol and a number, which I would definitely not expect to be at the start of the line.

      > Thinking about the type of change you're committing helps you create atomic commits. Anything that is not strictly related should go in a separate commit. Hopefully you already know why you should care about this.

      Yes. And I do this by thinking about a verb that naturally belongs at the beginning of the sentence (fragment) describing the commit. "Bugfix", "feature", and "enhancement" aren't actions.

      The discipline of organizing commits is orthogonal to the discipline of labeling them.

      > A conventional commit message also often includes the change scope.

      One that is thoughtfully written by hand will naturally include the scope of the change any time that this concept is meaningful.

imiric 3 hours ago

Eh, I wouldn't say it's a waste of bytes. Conventional Commits are useful for many scenarios.

This metadata could also be added via trailers, but most Git UIs don't show them prominently, or at all. So prefixing the subject is still the way to go.