From d49c72a9d7c80798d19692bb58e562509896b65d Mon Sep 17 00:00:00 2001 From: Fynn Freyer Date: Tue, 3 Aug 2021 18:27:16 +0200 Subject: [PATCH] remove requirement for curl in updateTaxonomy.sh added an if clause, that checks whether --only-build flag is set and only looks for curl if it isn't set --- KronaTools/updateTaxonomy.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/KronaTools/updateTaxonomy.sh b/KronaTools/updateTaxonomy.sh index 2f1df38..666e84f 100755 --- a/KronaTools/updateTaxonomy.sh +++ b/KronaTools/updateTaxonomy.sh @@ -23,8 +23,12 @@ ktPath=$(dirname $(readlink_f $0)) makefileAcc2taxid="scripts/accession2taxid.make" makefileTaxonomy="scripts/taxonomy.make" -command -v curl >/dev/null 2>&1 || \ - { echo >&2 "ERROR: Curl (http://curl.haxx.se) is required."; exit 1; } +# check if --only-build is set +# could potentially pick up false positives if other flags are added e.g. --only-build-and-fetch +if ! [[ $* == *--only-build* ]]; then + command -v curl >/dev/null 2>&1 || \ + { echo >&2 "ERROR: Curl (http://curl.haxx.se) is required."; exit 1; } +fi while [ "$#" -ne 0 ] do