git rebase request on a project

Paulo César Pereira de Andrade paulo.cesar.pereira.de.andrade at gmail.com
Mon Jan 21 14:34:43 UTC 2013


2013/1/21 Stanislav Ochotnicky <sochotnicky at redhat.com>:
> Quoting Stephen Gallagher (2013-01-18 15:27:30)
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>> On Fri 18 Jan 2013 06:55:26 AM EST, Paulo César Pereira de Andrade
>> wrote:
>> >   Sorry if this is a dumb question, but I cannot find any information.
>> >
>> >   I would like to have "git rebase master" on f16, f17, and f18
>> > branches of  http://pkgs.fedoraproject.org/cgit/megaglest.git
>> > I once messed it a bit by adding a commit only to branches and
>> > later merging master, now I cannot merge without a "merge master"
>> > commit, and am not allowed to push myself a "git rebase master"
>> > branch.
>>
>>
>> Rebases like that are not permitted in Fedora because they rewrite
>> history (and therefore mean we wouldn't be able to exactly recreate an
>> older build if we needed to). You're going to have to do the merge and
>> manage the merge conflicts appropriately (either via 'git merge' or by
>> starting from the tarball and working your way up again without a merge
>> commit).
>
> If I understood Paulo correctly, he merely wanted to linearize his history so he
> can continue doing fast-forward merges again. I've cross-merged branches so that
> they are now again on the same hash. Content of all branches (f16+) was the same
> so they were all without conflicts.

  Exactly, I want to do fast-forward merges, but I messed sometime
ago by pushing a commit only to branches.
  I also did not properly explain what I did want to push, it would be
basically:

$ fedpkg clone megaglest
$ cd megaglest
$ for branch in f16 f17 f18; do
      fedpkg switch-branch $branch
      git rebase master
      git rebase --skip
  done
$ git push --all

  But then I messed even more because I was not allowed to
push that.

  The conflict would be "Package currently is x86 specific (#855736)"
commit. But I think better to not try to fix it by adding that commit
to master now.
  The above would be to "clean" the history and remove the series
of "Merge branch ..." from the history, but it would be a cosmetic
change.

> For future, please do everything in master first :-)

  Thanks, I learned my lesson :-)

> Enjoy,
>
> --
> Stanislav Ochotnicky <sochotnicky at redhat.com>
> Software Engineer - Base Operating Systems Brno
>
> PGP: 7B087241
> Red Hat Inc.                               http://cz.redhat.com

Paulo


More information about the devel mailing list