Why did the GitHub windows client delete all of my work?

最后都变了- 提交于 2019-12-25 14:00:10

问题


Yesterday, I decided I wanted to upload all of my old crappy work. It is back when I was just starting programming and just wanted to show people it. I have never used git (very bad decision in my part) and created a repository. I downloaded the windows client and the egit eclipse plugin. I used the egit plugin but it just moved everything to a Oder and made it a local repository. I then used the windows client to submit a commit. It was taking a while so I left it on and went to sleep. I woke up this morning and everything was deleted except the folder names, .gitignore files and .project files from eclipse. Is there anyway I can get this old work back.

Thanks!


回答1:


At the root folder of your project, run gitk from the Git Bash and you'll see your changes.




回答2:


I have found a solution here: https://www.quora.com/Git-revision-control/How-do-I-retrieve-added-files-but-not-committed-from-a-reset?share=1

Basically you can retrieve the files from blobs but you have to do this one by one. I am writing a program to do so automatically now.

Is there any other easier way though?

If so, I would be glad to know.

Edit: Oh my I completely forgot about the previous versions tab on Windows. I'm just doing that.

Thanks!



来源:https://stackoverflow.com/questions/33832183/why-did-the-github-windows-client-delete-all-of-my-work

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!