标签云

微信群

扫码加入我们

WeChat QR Code

我如何能够获得一个与所有分支的Git仓库的全部内容吗?[重复]

This question already has an answer here:

I read here this text:

If you want to get a copy of an existing Git repository – for example, a project you’d like to contribute to – the command you need is git clone.

I need to get complete repository (with all branches).

But when I use the command git clone <address> <output_directory_name> then I get clone with one branch only. I see it through the git branch command. If I use the git clone <address> -b <branch_name> <output_directory_name> then I get only that branch (I see it through the git branch command again).

How can I get full content of a git repository with all branches? The repositories which I cloned are located on Bitbucket website.


I did git fetch --all after cloning, but I see one branch still.

2018年05月23日05分01秒

Try git branch --list.

2018年05月23日05分01秒