码迷,mamicode.com
首页 > 其他好文 > 详细

git undo last commit

时间:2016-04-12 22:24:07      阅读:286      评论:0      收藏:0      [点我收藏+]

标签:

$ git commit -m "Something terribly misguided"              (1)
$ git reset --soft HEAD~                                    (2)
<< edit files as necessary >>                               (3)
$ git add ...                                               (4)
$ git commit -c ORIG_HEAD                                   (5)


转自: http://stackoverflow.com/questions/927358/how-do-you-undo-the-last-commit

git undo last commit

标签:

原文地址:http://www.cnblogs.com/pinganzi/p/5384630.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!