git clone 指定分支下载

git clone -b <branch> <remote_repo>

Example:

git clone -b my-branch [email protected]:user/myproject.git

Alternative (no public key setup needed):

git clone -b my-branch https://[email protected]/username/myproject.git

With Git 1.7.10 and later, add --single-branch to prevent fetching of all branches. Example, with OpenCV 2.4 branch:

git clone -b opencv-2.4 --single-branch https://github.com/Itseez/opencv.git

猜你喜欢

转载自blog.csdn.net/qq_15505637/article/details/80839769
今日推荐