Mercurial > hg > easyhg
view easyhg-merge.bat @ 305:7708149d252a
Avoid exception when incremental log is called for in a situation where the heads have not actually been determined yet -- we could end up adding all existing history as an incremental update and getting a duplicate changeset error
author | Chris Cannam |
---|---|
date | Sat, 26 Feb 2011 23:04:05 +0000 |
parents | 256138a4ed0e |
children | d2e4bf428cfc |
line wrap: on
line source
@echo off setlocal enableextensions setlocal enabledelayedexpansion set mypath=%~dp0 set kdiff=kdiff3.exe set found= set SEARCH=%mypath%;%PATH% :loop for /F "delims=; tokens=1*" %%e in ("%SEARCH%") do ( if exist "%%e\%kdiff%" ( set found=%%e\%kdiff% goto done; ) set SEARCH=%%f ) if not "%SEARCH%"=="" goto loop; :done if "%found%"=="" ( echo. "Failed to find kdiff.exe in path" ) else ( "%found%" "%~2" "%~1" "%~3" -o "%~1" )