考录到有时候远程仓库很大,只需要拉取部分代码,操作说明如下
- 本地空白文件 执行
git init - 添加远程仓库地址
git remote add origin https:*****.git - 将sparsecheckout设置成开启状态
git config core.sparsecheckout true - 设置要获取的文件(文件夹)
echo resources >> .git/info/sparse-checkoutresources 为文件夹名 - 拉取
git pull orgin master(分支名)
成功截图


至此,整个过程就完成啦。
6150

被折叠的 条评论
为什么被折叠?



