Date: prev next · Thread: first prev next last
2010 Archives by date, by thread · List index


On Thu, 2010-11-18 at 10:30 +0100, Miklos Vajna wrote:
On Wed, Nov 17, 2010 at 08:28:36PM -0500, Kohei Yoshida <kyoshida@novell.com> wrote:
3) When creating a feature branch, by default, the autosetuprebase
option is set to true, which forces rebase when pulling from the master
branch even without the -r switch.  You need to manually specify
--no-rebase to disable rebase.

I'm very concerned about this, because with this setting, pulling from
the master into a feature branch, and push to the remote feature branch
fails (because you rebased).  Worse, when pushing to the remote fails,
git tells you to pull from the remote feature branch, but when you do
that, you lose the merging of the master you just did (bad).

And continuously pulling from the master branch is very common when you
are in a long-term feature branch, and messing up the branch history is
the last thing you want to see happen while the branch is still being
worked on.

That was added by me. I asked on this list and it was supposed to be a
good idea:

http://lists.freedesktop.org/archives/libreoffice/2010-October/000470.html

It's commit 7f24ede9ec00fea0482abc74a131d41c5578a915 in build.git. If
the consensus is that this is just annoying, I can revert it, sure.

IMNSO this is not just annoying, but plain dangerous, because mis-use of
rebasing may end up removing your local changes (or remote changes).
Now that we promote the concept of feature branches, I hope we can
revert this.

Also, I have no doubt that some of us will start using feature branches
to share development with others, and if my understanding is correct
(which it may not be) rebasing locally and pushing to the remote feature
branch when it's not fastforward would screw up the other person's
branch state...  Or is my understanding not correct?

The current workaround is to directly edit the .git/config file to
manually remove autosetuprebase=true from every feature branch you have,
but I wouldn't necessarily call it intuitive...

Actually you need to remove autosetuprebase from every repo, and 'rebase
= true' from each feature branch.

OK...  Thanks for pointing this out.

Either way, I hope someone who is a git expert can outline the correct
way of merging from master into a feature branch.  I still don't
understand what exactly 'rebase' does (I do only know it vaguely) in the
context of git (especially when pushing to remote), so I may end up
rebasing again when I shouldn't be.

Thanks,

Kohei

-- 
Kohei Yoshida, LibreOffice hacker, Calc
<kyoshida@novell.com>


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.