子线级合并工具?

发布于 2024-07-21 01:25:48 字数 231 浏览 6 评论 0原文

是否有任何交互式合并工具,当它们在给定行上出现合并冲突时,会返回并尝试对冲突行进行一次字符合并?

我正在考虑这样的情况:更改的代码行与缩进的同一行之间存在合并冲突。


顺便说一句:我正在使用从 TortoiseSVN 调用的 Beyond Compare

Are there any interactive merge tools that, when they get a merge conflict on a given line, go back and try to do a char-at-a-time merge of the conflicting lines?

I'm thinking of cases where you get a merge conflict between a changed line of code and the same line getting indented.


BTW: I'm using Beyond Compare called from TortoiseSVN

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

空气里的味道 2024-07-28 01:25:49
patch -l

忽略空格。

我不认为更通用的子行级合并对于代码来说不是一个好主意,除非它是交互式的; 如果您触摸的线路发生了变化,则很可能会出现问题。

patch -l

ignores whitespace.

I don't think a more general sub line level merge is a good idea for code unless it is interactive; if a line you've touched has changed there's a good chance something will break.

雨轻弹 2024-07-28 01:25:48

虽然这并不完全是您想要的,但我发现使用不同的 diff 工具(如 Kdiff)会更轻松地向您指出这一点。 (它们突出了字符差异。我还没有尝试过以这种方式合并)

在使用了一段时间后,我无法再忍受使用 Visual Studio 的内置差异。

用于配置此功能的一些资源:

http: //www.ytechie.com/2008/12/advantages-of-a-3rd-party-diffcompare-tool.html

http://blogs.msdn.com/jmanning/articles/535573.aspx

While this isn't exactly what you are looking for, I have found that using a different diff tool (like Kdiff) will point this out to you much more easily. (They highlight character differences. I have not tried merging in this fashion)

After using this for a while now, I can no longer stand using the built-in diff for Visual Studio.

Some resources for configuring this:

http://www.ytechie.com/2008/12/advantages-of-a-3rd-party-diffcompare-tool.html

http://blogs.msdn.com/jmanning/articles/535573.aspx

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文