comparison mercurial/filemerge.py @ 10533:184cdb66263e stable

filemerge: use native path separators when merging (issue1399)
author Patrick Mezard <pmezard@gmail.com>
date Tue, 23 Feb 2010 23:19:09 +0100
parents 23e608f42f2c
children 6f1894d6a6b0
comparison
equal deleted inserted replaced
10531:e3eff76552f1 10533:184cdb66263e
203 args = _toolstr(ui, tool, "args", '$local $base $other') 203 args = _toolstr(ui, tool, "args", '$local $base $other')
204 if "$output" in args: 204 if "$output" in args:
205 out, a = a, back # read input from backup, write to original 205 out, a = a, back # read input from backup, write to original
206 replace = dict(local=a, base=b, other=c, output=out) 206 replace = dict(local=a, base=b, other=c, output=out)
207 args = re.sub("\$(local|base|other|output)", 207 args = re.sub("\$(local|base|other|output)",
208 lambda x: '"%s"' % replace[x.group()[1:]], args) 208 lambda x: '"%s"' % util.localpath(replace[x.group()[1:]]), args)
209 r = util.system(toolpath + ' ' + args, cwd=repo.root, environ=env) 209 r = util.system(toolpath + ' ' + args, cwd=repo.root, environ=env)
210 210
211 if not r and _toolbool(ui, tool, "checkconflicts"): 211 if not r and _toolbool(ui, tool, "checkconflicts"):
212 if re.match("^(<<<<<<< .*|=======|>>>>>>> .*)$", fcd.data()): 212 if re.match("^(<<<<<<< .*|=======|>>>>>>> .*)$", fcd.data()):
213 r = 1 213 r = 1