首页 > 其他 > 详细

git clone

时间:2018-07-04 22:07:41      阅读:173      评论:0      收藏:0      [点我收藏+]

 

官方文档:https://git-scm.com/docs/git-clone

1  --depth<depth>     

  Create a shallow clone with a history truncated to the specified number of commits. Implies --single-branch unless --no-single-branch is given to fetch the histories near the tips of all branches. If you want to clone submodules shallowly, also pass --shallow-submodules.

  只克隆最近的一次commit

 

2 -b <name>

  Instead of pointing the newly created HEAD to the branch pointed to by the cloned repository’s HEAD, point to <name> branch instead. In a non-bare repository, this is the branch that will be checked out.--branch can also take tags and detaches the HEAD at that commit in the resulting repository.

  clone时某个<name>分支而不是默认Origin HEAD(master)

  示例:https://www.cnblogs.com/nylcy/p/6569284.html

git clone

原文:https://www.cnblogs.com/654321cc/p/9265480.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!