【已解决】git取消分支合并(fatal: There is no merge to abort (MERGE_HEAD missing).)

简介: git取消分支合并(fatal: There is no merge to abort (MERGE_HEAD missing).)

情况1:合并有冲突

git merge --abort

情况1:合并成功

合并成功后,上述命令就不能用了(用了会提示:fatal: There is no merge to abort (MERGE_HEAD missing).)
git log
# q 退出历史记录查询
git reset --hard 指定版本号 # 恢复到之前某个提交的版本,且舍弃该版本之后提交的版本

over

相关文章
|
1月前
|
开发工具 git
Git教程:深入了解删除分支的命令
【4月更文挑战第3天】
50 0
Git教程:深入了解删除分支的命令
|
2月前
|
开发工具 git 开发者
|
2月前
|
开发工具 git
|
3月前
|
前端开发 算法 开发工具
Git分支批量清理利器:自定义命令行插件实战
Git分支批量清理利器:自定义命令行插件实战
50 0
|
3月前
|
开发工具 git
git merge和git rebase异同
git merge和git rebase异同
71 0
|
3月前
|
开发工具 git
Git从远程仓库拉取指定的分支
Git从远程仓库拉取指定的分支
150 0
|
2月前
|
开发工具 git 开发者
|
2月前
|
开发工具 git
|
8天前
|
网络安全 数据安全/隐私保护
解决git@github.com: Permission denied (publickey). fatal: Could not read from remote repository. Pleas
解决git@github.com: Permission denied (publickey). fatal: Could not read from remote repository. Pleas
|
14天前
|
开发工具 git
避免git产生Merge branch 'foo' into 'bar'提交
避免git产生Merge branch 'foo' into 'bar'提交
34 3

相关实验场景

更多