TortoiseHG の diff の文字化け

この辺を参考
http://d.hatena.ne.jp/snegishi/20071023/1193117713
http://sinproject.blog47.fc2.com/blog-entry-29.html
http://d.hatena.ne.jp/Wacky/20080503/1209817242

@echo off
setlocal
:: Look in the registry for WinMerge location
for /f "skip=2 tokens=2*" %%A in (
    '"reg query "HKEY_CURRENT_USER\Software\Thingamahoochie\WinMerge" /v Executable 2> nul"' ) do set WMergePath=%%B
if "%WMergePath%"=="" (goto :notfound) else (goto :merge)

:merge
rem "%WMergePath%" /e /ub /wl /dl "Repository" %3 %1
"%WMergePath%" /dl Base /dm Local /dr Other /wl /wr %2 %1 %3

if %errorlevel% neq 0 (exit 1) else (exit 0)

:notfound
echo hgmerge: cannot find WinMerge location in the registry.
exit 1