我之前做了一个 git reset -hard FETCH_HEAD ,但我不知道要回到我最近的提交。
HEAD@{0}: checkout: moving from master to adding_events
HEAD@{1}: checkout: moving from adding_events to master
HEAD@{2}: checkout: moving from master to adding_events
HEAD@{3}: checkout: moving from 3458u9qfhaushf
HEAD@{4}: commit: Testing Gemfile edit
HEAD@{5}: checkout: moving from master to fajesnfkj24b
HEAD@{6}: commit: Changed Gemfile after reset
HEAD@{7}: reset: moving to FETCH_HEAD
HEAD@{8}: commit: Added Event Show page, Upload Event Pic
HEAD@{9}: commit: Add Category Database and Event pages
HEAD@{10}: merge adding_events: Fast-forward
HEAD@{11}: checkout: moving from adding_events to master
HEAD@{12}: commit: Replaced Post with Events
当我在我的主分支上执行 git status 时,这就是出现的情况
Your branch and 'origin/master' have diverged,
and have 1 and 5 different commits each, respectively.
当我在我的目录中打开应用程序时,12 次提交“用事件替换帖子”是显示的最新文件。我想回到我上次提交的 8 个“添加了活动显示页面,上传活动图片”......有什么想法吗?