8011342: hgforest.sh : 'python --version' not supported on older python

Tue, 02 Apr 2013 14:56:19 -0700

author
mduigou
date
Tue, 02 Apr 2013 14:56:19 -0700
changeset 681
7320922b694e
parent 680
bcbdbcfe7ed8
child 682
575f2ca947ab

8011342: hgforest.sh : 'python --version' not supported on older python
Reviewed-by: wetmore

common/bin/hgforest.sh file | annotate | diff | comparison | revisions
     1.1 --- a/common/bin/hgforest.sh	Tue Apr 02 11:55:09 2013 -0700
     1.2 +++ b/common/bin/hgforest.sh	Tue Apr 02 14:56:19 2013 -0700
     1.3 @@ -51,7 +51,7 @@
     1.4     bpython="`basename "$python"`"
     1.5  fi
     1.6  
     1.7 -if [ -x "$python" -a ! -d "$python" -a  "`${python} --version 2>&1 | cut -f 1 -d " "`" == "Python" ] ; then
     1.8 +if [ -x "$python" -a ! -d "$python" -a  "`${python} -V 2>&1 | cut -f 1 -d " "`" == "Python" ] ; then
     1.9    hg="${python} -u ${whichhg}"
    1.10  else
    1.11    echo Cannot find python from hg launcher. Running plain hg, which probably has buffered stdout.

mercurial