[Development] Rebasing a contribution

Thiago Macieira thiago.macieira at intel.com
Thu Nov 24 00:21:55 CET 2011


On Wednesday, 23 de November de 2011 21:33:14 Oswald Buddenhagen wrote:
> On Wed, Nov 23, 2011 at 07:07:17PM +0100, ext Thiago Macieira wrote:
> > So, if I have reviewed your patch #6 in the contribution and you need to
> > rebase in order to modify something, then rebase, push #7, leave a comment
> > saying it was a rebase, modify and submit #8. That way, I can compare #7
> > to #8 and note that you made the change I requested.
> 
> my guess is that most of the time the pull --rebase is the *last* thing
> people do, because that's what they always have done before pushing.

I don't see that as a problem. As long as you push the rebased version with no 
*other* modification. You don't need to rebase to update a contribution, you 
only rebase because you want or need to for other reasons.

> consequently, the right fix would be git reset --hard to the pre-rebase
> version from the reflog if the rebase is empty. except that nobody will
> do it. however, i have a todo item to write a git-gpush script which
> does just that automatically in the background.

Huh? You lost me completely here. Why would you need to go back?

> more interesting is the question what to do with non-empty rebases.
> 
> fwiw, http://code.google.com/p/gerrit/issues/detail?id=217

Yes, this is the issue in question. I don't know of a generic way of solving 
it with Git. That's why I am asking that, if people are going to submit 
rebases, submit ONLY the rebase, with no extra changes.

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center
     Intel Sweden AB - Registration Number: 556189-6027
     Knarrarnäsgatan 15, 164 40 Kista, Stockholm, Sweden
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.qt-project.org/pipermail/development/attachments/20111124/14e3c154/attachment.sig>


More information about the Development mailing list