有没有办法使用外部差异工具查看git历史记录? [英] Is there a way to view git history using external diff tool?

查看:130
本文介绍了有没有办法使用外部差异工具查看git历史记录?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我在git gui中查看git commit历史记录时,是否有一种方法可以使用外部diff工具来显示提交差异?

When I view a git commit history in git gui, is there a way to use an external diff tool to show commit differences?

推荐答案

当然, git difftool 。例如:

Sure, git difftool. For example:

git difftool -t gvimdiff master^..master

如果你在谈论 git-gui - 它使用 gitk code>内部查看历史记录。您可以使用编辑 - >首选项来配置外部差异工具。查看它的使用位置有点棘手:通常在查看差异时(通过选择提交或使用各种Diff this - > selected选项),使用右侧面板上的Patch视图,右键单击一个文件并选择外部差异。这将使用您配置的diff工具。

If you're talking about git-gui - it uses gitk internally for viewing history. You can configure an external diff tool using Edit->Preferences. It's a little tricky to see where it's used: When viewing a difference normally (either by selecting a commit or using the various "Diff this -> selected" options), using "Patch" view on the right-hand panel, right-click a file and select "External Diff". This will use the diff tool you configured.

这篇关于有没有办法使用外部差异工具查看git历史记录?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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