git从远程拉...我可以拉特定的提交? [英] git pull from remote... can I pull a specific commit?

查看:171
本文介绍了git从远程拉...我可以拉特定的提交?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在本地创建一个空的新存储库,我添加一个远程存储库。
现在,我想从远程存储库获取特定的提交,而无需下载整个远程存储库及其所有分支机构!

答案是

 

解决方案

git fetch origin 96de5297df870:refs / remotes / origin / D-commit

请参阅从远程Git存储库中检索特定提交


I create an empty new repository locally, I add a remote repository. Now I want to get a specific commit from the remote repository without downloading the whole remote repository with all its branches!

How do I do that?

解决方案

Answer is

git fetch origin 96de5297df870:refs/remotes/origin/D-commit

See Retrieve specific commit from a remote Git repository

这篇关于git从远程拉...我可以拉特定的提交?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆