git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] Give python a chance to find "backported" modules

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Nov 16, 2005, 02:33 UTC
Message-ID
<Pine.LNX.4.63.0511160331150.15130@wbgn013.biozentrum.uni-wuerzburg.de>

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>
---
	I noted that the python modules are installed uncompiled,
	i.e. *.py but not *.pyc. Is this intended?
 git-merge-recursive.py |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

applies-to: 2a67ad9e41fc614c7848ceff43f4b60b99cf932d dfd75a554e84139ddce7b62ec82ef94254da1573

diff --git a/git-merge-recursive.py b/git-merge-recursive.py
index 1bf73f3..d7d36aa 100755
--- a/git-merge-recursive.py
+++ b/git-merge-recursive.py
@@ -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
---
0.99.9.GIT
Next: Junio C Hamano
Message 1 of 4 in “Give python a chance to find "backported" modules”
  1. Give python a chance to find "backported" modulesJohannes Schindelin, Nov 16, 2005
  2. Junio C HamanoNov 16, 2005
  3. Johannes SchindelinNov 16, 2005
  4. Johannes SchindelinNov 18, 2005

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.