拉取 github 存储库时遇到问题
我有一个 github 存储库的分支,我想将其与 master 合并。我对使用 git 不太了解,几个月前,当我真正想做的是分支时,我分叉了。想通了这一点后,我就继续前进,没有多想。但我今天检查了我帐户的实际网站以获取存储库,我所做的所有工作都只提交给原始帐户,而不是我的帐户。当我分叉时,我的提交在几个月前就停止了。
我想知道如何使我的帐户具有与原始帐户相同的代码。
我尝试访问原始帐户的存储库并执行拉取请求。这给了我 -
Oops! The master branch is already up-to-date with master — maybe you want to try something else?
我不明白要比较什么才能得到我们的代码库相同的结果。
我尝试了这个终端命令 -
git pull https://github.com/jdannas/irobot_driver master
这给了我基本上相同的东西 -
From https://github.com/jdannas/irobot_driver
* branch master -> FETCH_HEAD
Already up-to-date.
这是图表的屏幕截图。所有提交都是我的,但您可以看到我的时间线在八月下旬停止,并且提交转到原始内容。
有人可以帮我弄清楚我需要做什么来解决这个问题吗?我被定向到 http://progit.org/book/,我肯定会同时阅读它以及整个未来,但如果我能在不阅读几个小时的情况下解决这个问题,那就太好了。感谢您的帮助。
I have a fork to a github repo that I want to merge with the master. I do not know much about using git and a few months ago I forked when what I really wanted to do was branch. After I figured that one out, I just moved on and didn't think anything of it. But I checked the actual website of my account for the repo today and all of the work I've been committing has only been committing to the original account and not mine. My commits stop months ago when I forked.
I want to know how to make it so that my account will have the same code as the original.
I tried a going to the original account's repo and doing a pull request. That gave me -
Oops! The master branch is already up-to-date with master — maybe you want to try something else?
I don't understand what it is comparing to get the result that our codebase is the same.
I tried this terminal command -
git pull https://github.com/jdannas/irobot_driver master
Which gave me basically the same thing -
From https://github.com/jdannas/irobot_driver
* branch master -> FETCH_HEAD
Already up-to-date.
Here is a screenshot of the graph. All of the commits are mine, but you can see that my timeline stops in late August and the commits go to the original.
Can someone help me figure out what I need to do to fix this? I was directed to http://progit.org/book/, which I will certainly be reading in meantime and throughout the future, but it would be great if I could get this issue resolved without reading for hours. Thank you for any help.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果您想将代码放入 sterlings 存储库中,则需要通过 GitHub UI(屏幕截图右上角的按钮)执行拉取请求。然后,这将要求维护者合并您的代码。
然后,您需要确保您在本地使用正确的存储库。最安全的方法是删除本地副本(备份!)并从英镑重新克隆。
If you want to put your code into the sterlings repo, you need to do a pull request via the GitHub UI (button's top right in your screenshot). This will then ask the maintainer to merge in your code.
You need to then ensure that you're working with the correct repo locally. The most bulletproof way of doing this is to blow away your local copy (backup!) and re-clone from sterlings.