view tests/testlib/pythonpath.sh @ 4638:7978db1dda3e

touch: extract the logic of touching rev's to its own function This refactoring will also help us in using the context manager for locks in next patches and also help reducing the nested depth.
author Sushil khanchi <sushilkhanchi97@gmail.com>
date Mon, 13 May 2019 18:39:43 +0530
parents 33fc61e5e119
children 277b45cf0dda
line wrap: on
line source

# utility to setup pythonpath to point into the tested repository

export SRCDIR="`dirname $TESTDIR`"
if [ -n "$PYTHONPATH" ]; then
    export HGTEST_ORIG_PYTHONPATH=$PYTHONPATH
    if uname -o | grep -q Msys; then
        export PYTHONPATH="$SRCDIR;$PYTHONPATH"
    else
        export PYTHONPATH=$SRCDIR:$PYTHONPATH
    fi
else
    export PYTHONPATH=$SRCDIR
fi