summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2010-04-22 22:29:07 -0700
committerJunio C Hamano <gitster@pobox.com>2010-04-22 22:29:07 -0700
commitdd0c5133c6994d2930485c579e701d79df632ded (patch)
tree42e0a9198ed7c9d356045652901ae8ce63b9dedd
parentDocumentation/Makefile: fix interrupted builds of user-manual.xml (diff)
parentMakefile: Remove usage of deprecated Python "has_key" method (diff)
downloadgit-dd0c5133c6994d2930485c579e701d79df632ded.tar.xz
git-dd0c5133c6994d2930485c579e701d79df632ded.zip
Merge branch 'da/maint-python-startup' into maint
* da/maint-python-startup: Makefile: Remove usage of deprecated Python "has_key" method
-rw-r--r--Makefile5
1 files changed, 2 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index e57d9754e28..5b868066060 100644
--- a/Makefile
+++ b/Makefile
@@ -1560,9 +1560,8 @@ $(patsubst %.py,%,$(SCRIPT_PYTHON)): % : %.py
-e '}' \
-e 's|^import sys.*|&; \\\
import os; \\\
- sys.path[0] = os.environ.has_key("GITPYTHONLIB") and \\\
- os.environ["GITPYTHONLIB"] or \\\
- "@@INSTLIBDIR@@"|' \
+ sys.path.insert(0, os.getenv("GITPYTHONLIB",\
+ "@@INSTLIBDIR@@"));|' \
-e 's|@@INSTLIBDIR@@|'"$$INSTLIBDIR"'|g' \
$@.py >$@+ && \
chmod +x $@+ && \