Undo a git reset
This question already has an answer here:
If you committed it, nothing is lost.
 If you have the reference of the commit, you can just git reset --hard <sha> to that precise commit.  
 In case you don't you can always use git reflog to retrieve the sha before performing the hard reset.  
 For instance if git reset --hard origin/master is the last command you run, you can do  
git reset HEAD@{1}
上一篇: GitHub:回到以前的版本并分支它
下一篇: 撤消git重置
