Re: config for merging master to test branch

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Daniel Convissor <danielc@xxxxxxxxxxxxxxxxxxxxxxxx> writes:

> On Mon, Dec 28, 2009 at 06:38:39PM -0500, Daniel Convissor wrote:
>> 
>> Now, here's the question.  I want to go back into the testing directory 
>> and do a "git pull" and have the changes from master automatically merged 
>> into my test branch in one step, without having to do an explicit set of 
>> checkouts and merges.
>
> I found this is possible by being in the "test" checkout and calling
> "git pull origin master".  Is this the best way to do it?

Good.  That is how it was designed to be used ;-)

If you feel lazy and want to omit typing " origin master", you could add a
few configuration items in your .git/config in the test repository.

    [branch "test"]
        remote = origin
        merge = refs/heads/master

That configures git in such a way that...

    When on branch "test", "pull" and "fetch" by default interact with the
    "origin" repository, and "pull" integrates what was found on the
    'master' branch from that remote into your history.

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]