squashing PRs

4 views
Skip to first unread message

Szczepan Faber

unread,
Aug 20, 2016, 1:03:47 PM8/20/16
to mocki...@googlegroups.com
Hey,

What's the team's recommendation for squashing PRs when merging?

Cheers!
--
Szczepan Faber
Founder @ mockito.org | Twitter @ szczepiq
Author @ https://www.linkedin.com/today/author/6016386

Tim van der Lippe

unread,
Aug 20, 2016, 2:08:48 PM8/20/16
to mocki...@googlegroups.com

We discussed this recently and did not come to a full agreement. In general we must strive for the cleanest and easiest to comprehend git history.


--
You received this message because you are subscribed to the Google Groups "mockito-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mockito-dev...@googlegroups.com.
To post to this group, send email to mocki...@googlegroups.com.
Visit this group at https://groups.google.com/group/mockito-dev.
For more options, visit https://groups.google.com/d/optout.

Szczepan Faber

unread,
Aug 21, 2016, 12:47:56 AM8/21/16
to mocki...@googlegroups.com
Let's give it another shot and apply a consistent strategy for the
next x months. Then assess.

I'm willing to try out squashing. Thoughts?

Cheers!

Brice Dutheil

unread,
Aug 22, 2016, 4:25:30 AM8/22/16
to mocki...@googlegroups.com

I’m willing to try out squashing. Thoughts?

I’m totally against that ! It destroy history, if comments are

  • refactoring
  • fix
  • wip
  • up
  • todo
  • misc
  • one another thing

It should be up to the developer to squash or rebase that in meaningful commit(s), eventually if the dev don’t reply then we can squash. However if the commits of a PR are already carefully crafted, so that each commit has it’s own set of change like

  • Fixes issue #42 : Mocks won’t accept anymore…
  • Update test dependencies

Then I’m against squashing the PR, it is plain wrong, and discard the work and care to provide a meaningful history.


-- Brice

On Sun, Aug 21, 2016 at 6:47 AM, Szczepan Faber <szcz...@gmail.com> wrote:
Let's give it another shot and apply a consistent strategy for the
next x months. Then assess.

I'm willing to try out squashing. Thoughts?

Cheers!

On Sat, Aug 20, 2016 at 11:08 AM, Tim van der Lippe
<tvande...@gmail.com> wrote:
> We discussed this recently and did not come to a full agreement. In general
> we must strive for the cleanest and easiest to comprehend git history.
>
>
> On Sat, 20 Aug 2016, 19:03 Szczepan Faber, <szcz...@gmail.com> wrote:
>>
>> Hey,
>>
>> What's the team's recommendation for squashing PRs when merging?
>>
>> Cheers!
>> --
>> Szczepan Faber
>> Founder @ mockito.org | Twitter @ szczepiq
>> Author @ https://www.linkedin.com/today/author/6016386
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "mockito-dev" group.
>> To unsubscribe from this group and stop receiving emails from it, send an

>> To post to this group, send email to mocki...@googlegroups.com.
>> Visit this group at https://groups.google.com/group/mockito-dev.
>> For more options, visit https://groups.google.com/d/optout.
>
> --
> You received this message because you are subscribed to the Google Groups
> "mockito-dev" group.
> To unsubscribe from this group and stop receiving emails from it, send an

> To post to this group, send email to mocki...@googlegroups.com.
> Visit this group at https://groups.google.com/group/mockito-dev.
> For more options, visit https://groups.google.com/d/optout.



--
Szczepan Faber
Founder @ mockito.org | Twitter @ szczepiq
Author @ https://www.linkedin.com/today/author/6016386

--
You received this message because you are subscribed to the Google Groups "mockito-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mockito-dev+unsubscribe@googlegroups.com.

Igor Czechowski

unread,
Aug 22, 2016, 1:30:12 PM8/22/16
to mocki...@googlegroups.com
I'm with Brice though I have not contributed to the project since long time.

I'd rather ask developer to squash if commits are messy & squash PR if
no action, but you find the pull request valuable.

We squash PR at work when there's a lot of going back and forth during
the review. However when PR is ready to be merged right away after the
review I rather prefer merge.

Igor
>> >> email to mockito-dev...@googlegroups.com.
>> >> To post to this group, send email to mocki...@googlegroups.com.
>> >> Visit this group at https://groups.google.com/group/mockito-dev.
>> >> For more options, visit https://groups.google.com/d/optout.
>> >
>> > --
>> > You received this message because you are subscribed to the Google
>> > Groups
>> > "mockito-dev" group.
>> > To unsubscribe from this group and stop receiving emails from it, send
>> > an
>> > email to mockito-dev...@googlegroups.com.
>> > To post to this group, send email to mocki...@googlegroups.com.
>> > Visit this group at https://groups.google.com/group/mockito-dev.
>> > For more options, visit https://groups.google.com/d/optout.
>>
>>
>>
>> --
>> Szczepan Faber
>> Founder @ mockito.org | Twitter @ szczepiq
>> Author @ https://www.linkedin.com/today/author/6016386
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "mockito-dev" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to mockito-dev...@googlegroups.com.
>> To post to this group, send email to mocki...@googlegroups.com.
>> Visit this group at https://groups.google.com/group/mockito-dev.
>> For more options, visit https://groups.google.com/d/optout.
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "mockito-dev" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to mockito-dev...@googlegroups.com.

Szczepan Faber

unread,
Aug 23, 2016, 12:01:09 AM8/23/16
to mocki...@googlegroups.com
Wow, strong opinions :)

I prefer small commits myself. However, I saw feedback to squash commits in PRs. So I figured if I do things differently than usual, perhaps I can learn more?

Anyhow, given how strong feelings Brice has for not squashing, I'm backing out from the idea. Let's play it on case by case basis. We leave it up to developer and PR reviewer to decide.

Cheers!

Igor Czechowski

unread,
Aug 23, 2016, 6:23:12 AM8/23/16
to mocki...@googlegroups.com
@Szepan

No sure what squash option you have in mind:
- squash commits for PR ?
- squash PR commits ?

Github offers to squash PR commits, nowadays, so there's no need to do
the former.

https://github.com/blog/2141-squash-your-commits

Igor

Brice Dutheil

unread,
Aug 23, 2016, 9:56:44 AM8/23/16
to mocki...@googlegroups.com
Yet you may loose the commit history when looking at git history with tools like (git log, tig, sourcetree, gitkraken, etc.)

-- Brice


>> >> >> To post to this group, send email to mocki...@googlegroups.com.
>> >> >> Visit this group at https://groups.google.com/group/mockito-dev.
>> >> >> For more options, visit https://groups.google.com/d/optout.
>> >> >
>> >> > --
>> >> > You received this message because you are subscribed to the Google
>> >> > Groups
>> >> > "mockito-dev" group.
>> >> > To unsubscribe from this group and stop receiving emails from it,
>> >> > send
>> >> > an

>> >> > To post to this group, send email to mocki...@googlegroups.com.
>> >> > Visit this group at https://groups.google.com/group/mockito-dev.
>> >> > For more options, visit https://groups.google.com/d/optout.
>> >>
>> >>
>> >>
>> >> --
>> >> Szczepan Faber
>> >> Founder @ mockito.org | Twitter @ szczepiq
>> >> Author @ https://www.linkedin.com/today/author/6016386
>> >>
>> >> --
>> >> You received this message because you are subscribed to the Google
>> >> Groups
>> >> "mockito-dev" group.
>> >> To unsubscribe from this group and stop receiving emails from it, send
>> >> an

>> >> To post to this group, send email to mocki...@googlegroups.com.
>> >> Visit this group at https://groups.google.com/group/mockito-dev.
>> >> For more options, visit https://groups.google.com/d/optout.
>> >
>> >
>> > --
>> > You received this message because you are subscribed to the Google
>> > Groups
>> > "mockito-dev" group.
>> > To unsubscribe from this group and stop receiving emails from it, send
>> > an

>> > To post to this group, send email to mocki...@googlegroups.com.
>> > Visit this group at https://groups.google.com/group/mockito-dev.
>> > For more options, visit https://groups.google.com/d/optout.
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "mockito-dev" group.
>> To unsubscribe from this group and stop receiving emails from it, send an

>> To post to this group, send email to mocki...@googlegroups.com.
>> Visit this group at https://groups.google.com/group/mockito-dev.
>> For more options, visit https://groups.google.com/d/optout.
>
> --
> You received this message because you are subscribed to the Google Groups
> "mockito-dev" group.
> To unsubscribe from this group and stop receiving emails from it, send an

> To post to this group, send email to mocki...@googlegroups.com.
> Visit this group at https://groups.google.com/group/mockito-dev.
> For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "mockito-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mockito-dev+unsubscribe@googlegroups.com.

Brice Dutheil

unread,
Aug 24, 2016, 5:17:58 AM8/24/16
to mocki...@googlegroups.com
For reference here's a comment of the infamous Linus Torvald on Github commits / PR. I cannot say I disagree with everything he says.


-- Brice

Marcin Grzejszczak

unread,
Aug 24, 2016, 9:17:34 AM8/24/16
to mockito-dev
My 2 cents...

I'd personally squash the commits (we do that in Spring Cloud and it works like a charm) but since we can't agree let's agree to disagree and let everybody do what they want ;)

-- Brice


-- Brice


>> >> >> To post to this group, send email to mocki...@googlegroups.com.
>> >> >> Visit this group at https://groups.google.com/group/mockito-dev.
>> >> >> For more options, visit https://groups.google.com/d/optout.
>> >> >
>> >> > --
>> >> > You received this message because you are subscribed to the Google
>> >> > Groups
>> >> > "mockito-dev" group.
>> >> > To unsubscribe from this group and stop receiving emails from it,
>> >> > send
>> >> > an

>> >> > To post to this group, send email to mocki...@googlegroups.com.
>> >> > Visit this group at https://groups.google.com/group/mockito-dev.
>> >> > For more options, visit https://groups.google.com/d/optout.
>> >>
>> >>
>> >>
>> >> --
>> >> Szczepan Faber
>> >> Founder @ mockito.org | Twitter @ szczepiq
>> >> Author @ https://www.linkedin.com/today/author/6016386
>> >>
>> >> --
>> >> You received this message because you are subscribed to the Google
>> >> Groups
>> >> "mockito-dev" group.
>> >> To unsubscribe from this group and stop receiving emails from it, send
>> >> an

>> >> To post to this group, send email to mocki...@googlegroups.com.
>> >> Visit this group at https://groups.google.com/group/mockito-dev.
>> >> For more options, visit https://groups.google.com/d/optout.
>> >
>> >
>> > --
>> > You received this message because you are subscribed to the Google
>> > Groups
>> > "mockito-dev" group.
>> > To unsubscribe from this group and stop receiving emails from it, send
>> > an

>> > To post to this group, send email to mocki...@googlegroups.com.
>> > Visit this group at https://groups.google.com/group/mockito-dev.
>> > For more options, visit https://groups.google.com/d/optout.
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "mockito-dev" group.
>> To unsubscribe from this group and stop receiving emails from it, send an

>> To post to this group, send email to mocki...@googlegroups.com.
>> Visit this group at https://groups.google.com/group/mockito-dev.
>> For more options, visit https://groups.google.com/d/optout.
>
> --
> You received this message because you are subscribed to the Google Groups
> "mockito-dev" group.
> To unsubscribe from this group and stop receiving emails from it, send an

> To post to this group, send email to mocki...@googlegroups.com.
> Visit this group at https://groups.google.com/group/mockito-dev.
> For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "mockito-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mockito-dev...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages