0

我有一个托管在 bitbucket 中的远程存储库,但是当我想将此存储库克隆到我的电脑时,
Bitbucket 克隆了主分支,我想克隆另一个名为 static_pages_exercises 的分支,它也托管在同一个远程项目中。那可能吗。

Error:it clones the remote master branch no the remote static-pages-exercises branch


daniel:~/workspace$ mkdir sample_app
daniel:~/workspace$ git init .
Reinitialized existing Git repository in /home/fernando/workspace/.git/
fernando@fernando:~/workspace$ git clone git@bitbucket.org:ferbad1212/sample_app.git
Cloning into 'sample_app'...
remote: Counting objects: 139, done.
remote: Compressing objects: 100% (124/124), done.
remote: Total 139 (delta 42), reused 0 (delta 0)
Receiving objects: 100% (139/139), 23.05 KiB, done.
Resolving deltas: 100% (42/42), done
4

1 回答 1

3

试试下面的命令

git clone --branch 分支名称 cloneUrl

例子

git clone --branch 功能https://cloneurl

于 2017-04-21T12:55:56.713 回答