Code

Give python a chance to find "backported" modules
authorJohannes Schindelin <Johannes.Schindelin@gmx.de>
Wed, 16 Nov 2005 02:33:44 +0000 (03:33 +0100)
committerJunio C Hamano <junkio@cox.net>
Wed, 16 Nov 2005 06:10:59 +0000 (22:10 -0800)
python 2.2.1 is perfectly capable of executing git-merge-recursive,
provided that it finds heapq and sets. All you have to do is to steal
heapq.py and sets.py from python 2.3 or newer, and drop them in your
GIT_PYTHON_PATH.

Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Signed-off-by: Junio C Hamano <junkio@cox.net>
git-merge-recursive.py

index 1bf73f336d4c34011b9cfe5a13b88a1f657d3f4e..d7d36aa7d11299d3a1e91dce1bc9572ac56a7c08 100755 (executable)
@@ -3,11 +3,13 @@
 # Copyright (C) 2005 Fredrik Kuivinen
 #
 
-import sys, math, random, os, re, signal, tempfile, stat, errno, traceback
+import sys
+sys.path.append('''@@GIT_PYTHON_PATH@@''')
+
+import math, random, os, re, signal, tempfile, stat, errno, traceback
 from heapq import heappush, heappop
 from sets import Set
 
-sys.path.append('''@@GIT_PYTHON_PATH@@''')
 from gitMergeCommon import *
 
 outputIndent = 0