From 37566e067645bf881b170796251a14d8d20202b8 Mon Sep 17 00:00:00 2001 From: Matthias Wachs Date: Thu, 28 Nov 2013 10:42:15 +0000 Subject: add cli check --- src/gns/test_gns_lookup.sh | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/gns/test_gns_lookup.sh') diff --git a/src/gns/test_gns_lookup.sh b/src/gns/test_gns_lookup.sh index 6eb16aa52..6a91e78a4 100755 --- a/src/gns/test_gns_lookup.sh +++ b/src/gns/test_gns_lookup.sh @@ -1,5 +1,13 @@ #!/bin/bash trap "gnunet-arm -e -c test_gns_lookup.conf" SIGINT + +LOCATION=$(which gnunet-config) +if [ -z $LOCATION ] +then + echo "GNUnet command line tools cannot be found, check environmental variables PATH and GNUNET_PREFIX" + exit 1 +fi + rm -r `gnunet-config -c test_gns_lookup.conf -s PATHS -o GNUNET_HOME -f` which timeout &> /dev/null && DO_TIMEOUT="timeout 30" TEST_IP="127.0.0.1" -- cgit v1.2.3