windows 什么是用于 Git 的好的(免费)可视化合并工具?(在窗户上)

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/7227826/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-09 08:44:27  来源:igfitidea点击:

What's a good (free) visual merge tool for Git? (on windows)

windowsgitversion-controlmerge

提问by Tal Galili

A similar questionwas already asked, but for Ubuntu.

一个类似的问题已经被问过,但对Ubuntu。

It would help to know if the tool is free as in beer or as in liber.

了解该工具是在啤酒中还是在 liber 中是免费的会有所帮助。

Also, up and downs of the tool would be nice to know.

此外,该工具的起起落落会很高兴知道。

采纳答案by VonC

On Windows, a good 3-way diff/merge tool remains kdiff3(WinMerge, for now, is still 2-way based, pending WinMerge3)

在 Windows 上,一个好的 3 路 diff/merge 工具仍然是kdiff3WinMerge,目前,仍然是基于 2 路的,待定的 WinMerge3)

See "How do you merge in GIT on Windows?" and this config.

请参阅“您如何在 Windows 上的 GIT 中合并?”和此配置



Update 7 years later (Aug. 2018): Artur K?dziormentions in the comments:

7 年后更新(2018 年 8 月):Artur K?dzior在评论中提到:

If you guys happen to use Visual Studio(Community Edition is free), try the tool that is shipped with it: vsDiffMerge.exe. It's really awesome and easy to use.

如果你们碰巧使用Visual Studio(社区版是免费的),请尝试使用它附带的工具:vsDiffMerge.exe. 它真的很棒而且易于使用。

回答by Gordolio

I've also used Meld. It's written in python. There is an official installer for Windows that works well.

我也用过Meld。它是用python编写的。有一个适用于 Windows 的官方安装程序运行良好。

Install it and then set it as your default mergetool.

安装它,然后将其设置为默认的合并工具。

$ git config --global merge.tool "meld"
$ git config --global mergetool.meld.path "C:\Program Files (x86)\Meld\Meld.exe"

If using a GUI GIT client, try the following (instructions for SourceTree, adjust accordingly)

如果使用 GUI GIT 客户端,请尝试以下操作(SourceTree 的说明,相应调整)

  • In SourceTree, go to Tools/Options/Diff
  • In External Diff Tool, choose Custom
  • Enter C:\Program Files (x86)\Meld\meld.exein Diff Command and $LOCAL $REMOTEin Arguments
  • In Merge Tool, choose Custom
  • Enter C:\Program Files (x86)\Meld\meld.exein Diff Command and $LOCAL $MERGED $REMOTEin Arguments
  • 在 SourceTree 中,转到工具/选项/差异
  • 在 中External Diff Tool,选择自定义
  • 输入C:\Program Files (x86)\Meld\meld.exeDiff 命令和$LOCAL $REMOTE参数
  • 在 中Merge Tool,选择自定义
  • 输入C:\Program Files (x86)\Meld\meld.exeDiff 命令和$LOCAL $MERGED $REMOTE参数

回答by Daniel Little

I've been using P4Merge, it's free and cross platform.

我一直在使用P4Merge,它是免费的和跨平台的。

P4Merge

P4合并

回答by Preet Sangha

I don't know a goodfree tool but winmerge is ok(ish). I've been using the beyond comparetools since 1999 and can't rate it enough - it costs about 50 USD and this investment has paid for it self in time savings more than I can possible imagine.

我不知道一个好的免费工具,但winmerge 是好的(ish)。自 1999 年以来,我一直在使用无与伦比的工具,但对它的评价不够高——它的成本约为 50 美元,而这项投资为它自己节省的时间所付出的代价超出了我的想象。

Sometimes tools should be paid for if they are very very good.

有时,如果工具非常好,就应该付费。

回答by Lazy Badger

  • TortoiseMerge (part of ToroiseSVN) is much betterthan kdiff3 (I use both and can compare);
  • p4merge (from Perforce) works also very well;
  • Diffuse isn't so bad;
  • Diffmerge from SourceGearhas only one flawin handling UTF8-files without BOM, making in unusable for this case.
  • TortoiseMerge(ToroiseSVN 的一部分)比 kdiff3好得多(我两者都用,可以比较);
  • p4merge(来自 Perforce)也很好用;
  • 漫反射并没有那么糟糕;
  • SourceGear 的 Diffmerge在处理没有 BOM 的 UTF8 文件时只有一个缺陷,在这种情况下无法使用。

回答by eckes

Another free option is jmeld: http://keeskuip.home.xs4all.nl/jmeld/

另一个免费选项是 jmeld:http://keeskuip.home.xs4all.nl/jmeld/

It's a java tool and could therefore be used on several platforms.

它是一个 Java 工具,因此可以在多个平台上使用。

But (as Preetmentioned in his answer), freeis not always the best option. The best diff/merge tool I ever came across is Araxis Merge. Standard edition is available for 99 EUR which is not that much.

但是(正如Preet在他的回答中提到的),免费并不总是最好的选择。我遇到的最好的差异/合并工具是Araxis Merge。标准版的售价为 99 欧元,这并不多。

They also provide a documentationfor how to integrate Araxis with msysGit.

他们还提供了有关如何将 Araxis 与 msysGit 集成的文档

If you want to stick to a free tool, JMeldcomes pretty close to Araxis.

如果您想坚持使用免费工具,JMeld与 Araxis 非常接近。

回答by user1553825

What's wrong with using Git For Windows? From the repo view, there's an icon of the branch you're in (at the top), and if you click on manage you can drag&drop in a very visual and convenient way.

使用 Git For Windows 有什么问题?从 repo 视图中,有一个你所在分支的图标(在顶部),如果你点击管理,你可以以非常直观和方便的方式拖放。