multiple changes in one line with diff tool?

风格不统一 提交于 2020-01-01 11:02:20

问题


Normally, 'diff' tool finds only changes between lines. For example, if i compare 'abcdef' and 'AbcdEf', diff will show that 'abcde' is changed and 'f' is unchanged. Is it possible to find multiple changes per line, so in example above i will see that it's only 'a' changed to 'A' and 'e' changed to 'E'? Or diff outut format does not support such?


回答1:


There are multiple diff tools that will do what you're asking for.

Off the top of my head I know Winmerge and TortoiseMerge does that.




回答2:


I recommend KDiff3 which highlights with different colours changes on the same line.




回答3:


I wrote a tool to diff web code regardless of differences from comments and whitespace. This means my tool can diff a completely minified file against a similar beautified file. It is written entirely in JavaScript so you try it directly in your browser without downloading or installing anything. This does highlight differences per line and highlights differences per characters on those lines.

http://prettydiff.com/



来源:https://stackoverflow.com/questions/1265949/multiple-changes-in-one-line-with-diff-tool

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!