Git比较“base”版本与“他们的”冲突文件的版本? [英] Git compare "base" version with "theirs" version of a conflicted file?

查看:171
本文介绍了Git比较“base”版本与“他们的”冲突文件的版本?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

给定一个冲突的文件 foo.txt ,如何判断 git diff 来显示基本版本该文件和文件的他们的版本?

我可以通过 git show:1:foo.txt查看每个版本 code>或 git show:3:foo.txt - 是否有一种比较两个版本的简单方法?

解决方案

git diff:1:foo.txt:3:foo.txt

Given a conflicted file foo.txt, how to tell git diff to show changes between the base version of the file and "their" version of the file?

I can see each of the versions via git show :1:foo.txt or git show:3:foo.txt - is there a simple way to compare the two versions?

解决方案

git diff :1:foo.txt :3:foo.txt

这篇关于Git比较“base”版本与“他们的”冲突文件的版本?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆