From 88f8f0a52b2962452d89e854ad751283595473e4 Mon Sep 17 00:00:00 2001 From: Fredrik Kuivinen Date: Mon, 3 Oct 2005 08:13:09 +0200 Subject: [PATCH] Enable and fix support for base less merges. Let the merge strategies handle the base less case if they are able to do it. It also fixes git-resolve.sh to die if no common ancestors exists, instead of doing the wrong thing. Furthermore, it contains a small independent fix for git-merge.sh and a fix for a base less code path in gitMergeCommon.py. With this it's possible to use git merge -s recursive 'merge message' A B to do a base less merge of A and B. [jc: Thanks Fredrik for fixing the brown-paper-bag in git-merge. I fixed a small typo in git-merge-resolve fix; 'test' equality check is spelled with single equal sign -- C-style double equal sign is bashism.] Signed-off-by: Fredrik Kuivinen Signed-off-by: Junio C Hamano --- gitMergeCommon.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gitMergeCommon.py') diff --git a/gitMergeCommon.py b/gitMergeCommon.py index 7e8855c61..1b5bddd46 100644 --- a/gitMergeCommon.py +++ b/gitMergeCommon.py @@ -213,7 +213,7 @@ def buildGraph(heads): # Write the empty tree to the object database and return its SHA1 def writeEmptyTree(): - tmpIndex = os.environ['GIT_DIR'] + '/merge-tmp-index' + tmpIndex = os.environ.get('GIT_DIR', '.git') + '/merge-tmp-index' def delTmpIndex(): try: os.unlink(tmpIndex) -- cgit v1.2.1