我之前用 --depth 1 做了一个 git 浅克隆
之后,我想从远程获取一个深度为 10 的特定分支并结帐到该分支。
我能够从远程获取分支,但分支没有显示在git branch -a
更换个人信息后的日志如下
User@PC-NAME MINGW64 /d/Folder/application (master)
$ git fetch --depth 10 origin branchname
remote: Counting objects: 18624, done.
remote: Compressing objects: 100% (10327/10327), done.
remote: Total 18624 (delta 12993), reused 12045 (delta 7599)
Receiving objects: 100% (18624/18624), 530.73 MiB | 1.36 MiB/s, done.
Resolving deltas: 100% (12993/12993), completed with 3067 local objects.
From 10.100.x.x:Repository/application
* branch branchname -> FETCH_HEAD
User@PC-NAME MINGW64 /d/Folder/application (master)
$ git branch -a
* master
remotes/origin/HEAD -> origin/master
remotes/origin/master