Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice

Feedback Pull Requests should be squashed before merging

Discussion in 'Open Projects' started by hemanthvanam, Oct 6, 2020.

  1. hemanthvanam

    hemanthvanam

    Joined:
    Mar 3, 2019
    Posts:
    11
    Hey guys, I think the pull requests should be squashed before merging as this will come in handy when tracking a bug and also it makes the commits more readable and understandable.

    For those who don't know squashing in git it basically combines all of your commits in your PR branch into one whole commit and then merges into the main repository.

     
    Last edited: Oct 6, 2020
    cirocontinisio likes this.
  2. Kamyker

    Kamyker

    Joined:
    May 14, 2013
    Posts:
    1,086
    True, cleaner image
     
    hemanthvanam likes this.
  3. MileyUnity

    MileyUnity

    Joined:
    Jan 3, 2020
    Posts:
    92
    From looking at the current history of the master branch I think @cirocontinisio is already doing that, if not then yes I definitely agree that we should squash each PR before merging them in
     
    hemanthvanam likes this.
  4. cirocontinisio

    cirocontinisio

    Joined:
    Jun 20, 2016
    Posts:
    884
    I think up to now I was using "Create a merge commit" and it was fine for most merges that only had 1 commit, but recently merged one that had 4 (?)

    upload_2020-10-6_20-11-48.png

    If nobody has anything against it, I'll start using "Squash and Merge".

    Thanks for the input, @hemanthvanam!