On 2013-01-17 12:22, David Holmes wrote:
On 17/01/2013 10:53 AM, Mike Duigou wrote:
With the mac ports version of mercurial (wasn't I just complaining
about another mac ports problems yesterday? ;-) ) the path to python
in the mercurial launcher has is
/opt/local/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python
Note the capital "P" which is what was running afoul of the
hgforest.sh detection. The following patch uses a different technique
for checking the python executable.
Mike
PS:- I assume that the make/scripts/hgforest.sh is going away at some
point?
Why? What would replace it?
David
common/bin/hgforest.sh was added a while back.
/Erik
diff --git a/common/bin/hgforest.sh b/common/bin/hgforest.sh
--- a/common/bin/hgforest.sh
+++ b/common/bin/hgforest.sh
@@ -51,7 +51,7 @@
bpython="`basename "$python"`"
fi
-if [ "python" = "$bpython" -a -x "$python" ] ; then
+if [ -x "$python" -a ! -d "$python" -a "`${python} --version 2>&1 |
cut -f 1 -d " "`" == "Python" ] ; then
hg="${python} -u ${whichhg}"
else
echo Cannot find python from hg launcher. Running plain hg, which
probably has buffered stdout.