一個懶惰又不務正業的 .NET Core 工程師筆記...
查了一下資料 git 在版本 1.7.10 後提供了 --single-branch 的選項可滿足該需求,如下
--single-branch
$ git clone --single-branch --branch <branchname> <remote-repo>
Example:
$ git clone --single-branch --branch dev https://github.com/linmasaki/Kendo.DynamicLinqCore.git
[Stack Overflow] How do I clone a single branch in Git