• BatmanAoD@programming.dev
    link
    fedilink
    arrow-up
    2
    ·
    edit-2
    9 months ago

    Doesn’t squashing on merge achieve exactly the same thing? (As long as pull requests are kept small, of course.)

    • Kissaki@programming.dev
      link
      fedilink
      English
      arrow-up
      1
      ·
      8 months ago

      To a degree, if pull requests are small enough, then yes.

      Often, a changeset includes different aspects and concerns though, and individual commit messages allow you to document and reason them. Squashing makes you lose the concern separation.

      When reviewing, even relatively simple changes separated into their concerns helps me a lot.

      It’s a matter of preference and necessity, and the changeset and it’s environment at hand.

      • BatmanAoD@programming.dev
        link
        fedilink
        arrow-up
        0
        ·
        8 months ago

        Not squashing before review, squashing on merge (i.e. after review). Squashed merges make these easy, regardless of whether the original commits in the pull request were messy:

        • determining what changed between versions
        • finding and reverting regressions