문제

I've been using WinMerge, Eclipse's compare tool and Tortoise's to see my changes before committing. The problem is that when I edit a file that hasn't been edited by someone else since we last updated our autoformatter-configuration I'll see many, many changes caused by the autoformatter. Now I have to copy the code from the previous revision, autoformat it in Eclipse and copy it into WinMerge to only see I really made.

Is there a tool that can automatically autoformat both versions of the file I'm comparing?

도움이 되었습니까?

해결책

Any diff tool that allows you to set up an external conversion before the comparison should handle that. External conversions are primarily intended for things like Word/Excel/PDF to Text conversion, but you can do anything you want as long as you can run it from the command line.

For Beyond Compare we already have an optional add-on rule that will use Jalopy to format Java source and another one that use HTML Tidy for HTML files.

WinMerge doesn't look like it supports a Java reformatter out of the box, but their plugins page does describe how you could add one using a dll or Windows Scripting Host scriptlet.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top