tests/testlib/pythonpath.sh
author Anton Shestakov <av6@dwimlabs.net>
Fri, 17 May 2019 17:42:06 +0800
changeset 4655 bb0a5beb0ad8
parent 4336 33fc61e5e119
child 5316 277b45cf0dda
permissions -rw-r--r--
stack: remove unnecessary prefix from stack output with non-default --template "index" template keyword already exists (the current iteration of the loop), so "stack_index" it is. It follows the same convention as other template keywords, such as "files_added", "line_number", etc.

# 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