# Install utilities. Expects BIN_DIR to be set as the destination for utilities
# to be installed.
# Each utilities folder (peers with this script) should have a top-level
# install.sh script, which will be called with BIN_DIR set. Each directory MAY
# have a top-level test.sh script, which will run tests for the utility.
# If TEST is set, then tests will be run rather than performing the install.
cd "$(dirname "$0")"
for d in ./* ; do
if [ ! -d "$d" ] ; then
if [ ! -e "$d/install.sh" ] ; then
if [ ! -z "$TEST" ] ; then
if [ -e "$d/test.sh" ] ; then
BIN_DIR="$BIN_DIR" sh "$d/install.sh"