[Insight-developers] Gerrit for dummies (me)

David Doria daviddoria at gmail.com
Thu Apr 14 16:23:44 EDT 2011


On Thu, Apr 14, 2011 at 4:17 PM, Bill Lorensen <bill.lorensen at gmail.com>wrote:

> Folks,
>
> It happens to me every once in a while. I want to upload a new patch
> to an existing topic. I do a git rebase -i HEAD~2 and squash the last
> commit. I want the patch to show up with the original topic. Yes, I
> know that I must delete the second change-id from the commit message.
> But, sometimes I forget. So my patch shows up as a new gerrit topic.
>
> If this is a common mistake (maybe it's just me), then perhaps the
> hook could refrain from adding the second change-id. Or maybe my use
> case is bogus.
>
> Bill
>

It's not bogus, I do the same thing constantly. I would definitly favor the
correct Change-Id being put in the right place automatically.

In fact, instead of rebase -i HEAD~2, I would suggest a script called git
gerrit-singlecommit which does the rebase and squashing automatically. I bet
a very common workflow is "I just want it to be a single patch on Gerrit".

David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/mailman/private/insight-developers/attachments/20110414/e677a4d2/attachment.htm>


More information about the Insight-developers mailing list