git sparse-checkout, 只拉取部分目录

https://github.com/google-research/google-research/tree/master/ google这个仓库太大,我只要instruction_following_eval这个目录,其他目录、git信息啥的都不关心,方法如下:

shell 复制代码
git clone --filter=blob:none --no-checkout https://github.com/google-research/google-research.git --depth=1
cd google-research
git sparse-checkout init --cone
git sparse-checkout add instruction_following_eval
git checkout master

git clone命令中,--no-checkout表示不检出,即先不拉取文件;--filter=blob:none 只下载必要meta数据,进一步减少下载量;--depth=1 限制git历史信息,进一步减少下载量;整体就很快了。

相关推荐
云和数据.ChenGuang12 分钟前
git commit复合指令
大数据·git·elasticsearch
-拟墨画扇-4 小时前
Git | 文件提交操作
git·gitee·github·gitcode
CoderJia程序员甲4 小时前
GitHub 热榜项目 - 日榜(2025-12-25)
git·ai·开源·llm·github
-拟墨画扇-5 小时前
Git | 文件修改操作
大数据·git·gitee·github·gitcode
-拟墨画扇-5 小时前
Git | 版本控制操作
大数据·git·gitee·github
GA6666667 小时前
PowerWiki:基于 Git 的知识管理系统
git
-拟墨画扇-8 小时前
Git | 状态查看操作
git·gitee·github·gitcode
码灵8 小时前
Git相关软件常用操作
git
-拟墨画扇-8 小时前
Git | 简介与安装
大数据·git·elasticsearch
junlaii9 小时前
Windows Claude Code Git Bash 依赖修复教程
windows·git·bash