• atzanteol ( atzanteol@sh.itjust.works ) 
    link
    fedilink
    English
    arrow-up
    12
    ·
    2 days ago

    Fuck no. Stop trying to stuff data into commit messages. Just describe your change succinctly so I know what you did. This “feat” “fix” and “chore” bullshit needs to stop.

      • atzanteol ( atzanteol@sh.itjust.works ) 
        link
        fedilink
        English
        arrow-up
        2
        ·
        2 days ago

        Fine - then add 3-5 actually random letters to the start of all your commits from now on.

        No? I don’t understand what you’re so upset about…

        Because it’s NOISE that I’m sifting through as a tech lead. And they’re often lies anyway. “feats” can have refactors and bug fixes. fix can add new features. Devs are horribly bad at separating out these types of changes neatly when making commits. “chore” is just too cute by half. I know “Version bump: 1.2.3” is just a version bump - I don’t need you to whine about it being a chore.

        • It sounds to me like you’re just dealing with people who write bad commit messages.

          Or commits in general if you’re dealing with “feats” containing bug fixes.

          It doesn’t sound to me like your core problem is with conventional commits themselves, but rather with how they’re done in your experience.
          Inconsistency and unclear meaning does make it just some random noise, but that’s not how the standard is meant, that’s just people using it irresponsibly.

          “chore” is just too cute by half. I know “Version bump: 1.2.3” is just a version bump - I don’t need you to whine about it being a chore.

          Worth noting that only fix and feat are actual types defined by the official spec. chore is only listed as an example of what custom types you could use. So as long as you make sure the rest of the team is on the same page, you can also use a different noun like bump or version instead.

          “feats” can have refactors and bug fixes. fix can add new features. Devs are horribly bad at separating out these types of changes neatly when making commits.

          Actually looking through Conventional Commit’s page again, I also found this on-topic Q&A question:

          What do I do if the commit conforms to more than one of the commit types?
          Go back and make multiple commits whenever possible. Part of the benefit of Conventional Commits is its ability to drive us to make more organized commits and PRs.

          When both a bug fix and a feat are in the same commit, the answer isn’t to use one or the other, but to simplify the commit. I personally see more valid overlap with refactor (which isn’t an official type), but with these two, it’s inexcusable imo.

      • TehPers ( TehPers@beehaw.org ) 
        link
        fedilink
        English
        arrow-up
        1
        ·
        9 hours ago

        In your PR:

        ## Release notes
        
        - Fixed foo returning baz instead of bar when qux is passed in
        

        Your commit messages are pretty useless to the people actually reading the changelogs. If you need automatic changelog generation, then stitch it from parts written for humans to read.

      • atzanteol ( atzanteol@sh.itjust.works ) 
        link
        fedilink
        English
        arrow-up
        4
        ·
        2 days ago

        You don’t. Users are different audience than the development team. Messages intended for one group are different from those for the other. This is my biggest gripe about this “semantic” BS. Commit comments are for the dev team. You should summarize it in a way that makes sense to users.

        Every time I see a “changelog” from a team for something I use that is full of “fix: loop pointer in Foo.java” I just roll my eyes. Like that tells me anything useful. If I cam technically savvy enough and care I can go look at the git history. But as a user that’s meaningless.

    • Kissaki ( Kissaki@programming.dev ) 
      link
      fedilink
      English
      arrow-up
      2
      ·
      2 days ago

      I want to be able to scan a commit log, not just read commit titles one by one.

      The type gives me a scoping of to be expected intention, change size, and potential for side effects. docs never have runtime side effects.

      The scope gives me categories to scan for. Which area of the project am I searching for? Which product feature? If there’s a user bug, I can check those in the specific area and more general ones first.

      I need scope to be small, so the visual scanability is not broken because of horizontal shifting of the actual commit change title.

      I made sure my team capitalizes the commit change title, as an additional visual queue for scanability; being able to blend out the prefix.

      Even if you don’t care about changelog generating or log scanability for developers searching, debugging, or analyzing, I find deliberate commit messages practice helpful in guiding both in thought and documenting though of what the intention of the commit is, whether to split changes because they’re logically unrelated/not the same step, etc.

      In a small project or freshly started project before going stable or sizable it may not be necessary, but I still enjoy following the general practice.

      (cut off because it’s a customer project, just to be sure)

      No prefixes is a lot less useful. Commits can provide structure and guidance.

      Personally, I don’t like chore though, and we don’t use it in our project, reducing the number of types. Typically, those are misc(proj) or misc(ci) instead.

      The customer receives a list of feat and fix commit titles as info with a release.

      Commits are already data. Metadata about changes. Merge commits are structured data, putting individual changes into structured context. Using short well defined prefixes/prefix formats is a logical extension.

      • atzanteol ( atzanteol@sh.itjust.works ) 
        link
        fedilink
        English
        arrow-up
        1
        ·
        2 days ago

        The customer receives a list of feat and fix commit titles as info with a release.

        The problem is that the language customers want and the language developers want are different things. Abusing commit messages to try to create documentation is just a bad idea. Spend a few mins to summarize for your users what has changed. You should be able to pull the tickets that went into a release for that pretty easily. Hell have AI do it if you’re that lazy. But as a developer I want to know what your commit did. Just explain your change in a way that will help me later on.

        • Kissaki ( Kissaki@programming.dev ) 
          link
          fedilink
          English
          arrow-up
          2
          ·
          19 hours ago

          I find a commit message describing consequential effect and intended goal/change more useful than technical details. And those are usually what the customer cares about. “function/action works again” “fix x by y” “introduce functionality x”.

          But as a developer I want to know what your commit did.

          I agree. I don’t see them as opposites or contradicting to pulling them. Either as a free information forward, or as a basis for describing it into something a customer understands, or into what is notable about a release.

    • Agreed. Just write like a normal person. Conventional commits is such an engineer thinig to do (I say this as a software engineer myself). It’s an overengineered solution for something that should just be a human message.

        • What worth is there in grepping for feat or chore? Seems pointless to me. Besides, you could also just grep through the git history of the actual code instead of grepping commit messages.

          Also, maybe I’m the weird one here, but in my career as a software engineer, I’ve never had to search through commits in such a way. There’s always been better options, like looking at the blame or history of a particular section of code or a file or something like that.