-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrun-tox.sh
executable file
·33 lines (29 loc) · 997 Bytes
/
run-tox.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/usr/bin/env bash
#
# Copyright (C) 2015 <[email protected]>
#
# Author: Loic Dachary <[email protected]>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU Library Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Library Public License for more details.
#
# run from the ceph-disk directory or from its parent
: ${CEPH_DISK_VIRTUALENV:=/tmp/ceph-disk-virtualenv}
test -d ceph-disk && cd ceph-disk
if [ -e tox.ini ]; then
TOX_PATH=`readlink -f tox.ini`
else
TOX_PATH=`readlink -f $(dirname $0)/tox.ini`
fi
if [ -z $CEPH_BUILD_DIR ]; then
export CEPH_BUILD_DIR=$(dirname ${TOX_PATH})
fi
source ${CEPH_DISK_VIRTUALENV}/bin/activate
tox -c ${TOX_PATH}