Re: how to clone all branches include remote branches

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

 



On 2009-02-10, gnu kevin <kevin.gnu.zhang@xxxxxxxxx> wrote:
> I'd like to know how to get all remote(grandparent) branches by clone
> a remote repo . for example:
> remote repo ABC contains below branches:
> master
> stable/main
> dev/main

You could (if your .git/config) already contains the remote simply add a 
line:
fetch = +refs/remotes/*:refs/remotes/<remote-name>/remotes/*

The double remotes is used so that no remote-remote-branch can overwrite 
your tracking branch with the same name.

Hope that helped,
Jojo

-- 
Johannes Gilger <heipei@xxxxxxxxxxxx>
http://hackvalue.de/heipei/
GPG-Key: 0x42F6DE81
GPG-Fingerprint: BB49 F967 775E BB52 3A81  882C 58EE B178 42F6 DE81

--
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]

  Powered by Linux