From: Sebastian Wagner Date: Tue, 27 Aug 2019 08:36:43 +0000 (+0200) Subject: script/run_tox.sh: Don't overwrite the Ceph's bulid dir X-Git-Tag: v15.1.0~1370^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=8826afd84e27c0d7b3172d82532a69a05bc0bcd6;p=ceph-ci.git script/run_tox.sh: Don't overwrite the Ceph's bulid dir Signed-off-by: Sebastian Wagner --- diff --git a/src/script/run_tox.sh b/src/script/run_tox.sh index 14e3e641d94..101f52ced39 100755 --- a/src/script/run_tox.sh +++ b/src/script/run_tox.sh @@ -27,15 +27,15 @@ example: following command will run tox with envlist of "py27,py3" using the "tox.ini" in current directory. - $prog_name --tox-env py27,py3 + $prog_name --tox-envs py27,py3 following command will run tox with envlist of "py27" using "src/pybind/mgr/ansible/tox.ini" - $prog_name --tox-env py27 ansible + $prog_name --tox-envs py27 ansible following command will run tox with envlist of "py27" using "/ceph/src/python-common/tox.ini" - $prog_name --tox-env py27 --tox-path /ceph/src/python-common + $prog_name --tox-envs py27 --tox-path /ceph/src/python-common EOF } @@ -121,6 +121,11 @@ function main() { fi if [ ! -f ${venv_path}/bin/activate ]; then + if [ -d "$venv_path" ]; then + cd $venv_path + echo "$PWD already exists, but it's not a virtualenv. test_name empty?" + exit 1 + fi $source_dir/src/tools/setup-virtualenv.sh ${venv_path} fi source ${venv_path}/bin/activate