TWi*_*Rob 6 git download git-clone revision-history
如何克隆 git 存储库而不获取实际文件及其所有修订版本增量?我只想能够做到这一点git log | grep,不需要访问文件的内容。
我想跳过克隆的这一部分:
Receiving objects: 12% (359112/2981072), 432.66 MiB | 1.67 MiB/s
Run Code Online (Sandbox Code Playgroud)
我想对某些存储库的日志进行 grep,但无需下载/签出整个存储库,因为它们的重量为千兆字节。即使是我只获取单个分支日志(例如 master)的解决方案也让我感兴趣,如果有帮助的话。
本质上我正在寻找类似svn log <repo url>for的东西git。
部分克隆现在可以在更新版本的 git 中使用:
git clone --filter=blob:none --no-checkout git@github.com:foo/bar.git
Run Code Online (Sandbox Code Playgroud)