From: Fredrik Kuivinen Date: Fri, 11 Nov 2005 23:55:36 +0000 (+0100) Subject: merge-recursive: Use '~' instead of '_' to separate file names from branch names X-Git-Tag: v0.99.9h^2~16 X-Git-Url: https://git.octo.it/?a=commitdiff_plain;ds=sidebyside;h=e9af60c88bbd152ad04640ddb93dc927fc7a10b6;p=git.git merge-recursive: Use '~' instead of '_' to separate file names from branch names Makes it less probable that we get a clash with an existing file, furthermore Cogito already uses '~' for this purpose. Signed-off-by: Fredrik Kuivinen Signed-off-by: Junio C Hamano --- diff --git a/git-merge-recursive.py b/git-merge-recursive.py index 21f1e924..1bf73f33 100755 --- a/git-merge-recursive.py +++ b/git-merge-recursive.py @@ -304,13 +304,13 @@ def uniquePath(path, branch): raise branch = branch.replace('/', '_') - newPath = path + '_' + branch + newPath = path + '~' + branch suffix = 0 while newPath in currentFileSet or \ newPath in currentDirectorySet or \ fileExists(newPath): suffix += 1 - newPath = path + '_' + branch + '_' + str(suffix) + newPath = path + '~' + branch + '_' + str(suffix) currentFileSet.add(newPath) return newPath