#!/bin/bash SCRIPT_PATH=$(readlink -f "$0") export PATH=$PATH:`dirname $SCRIPT_PATH` # echo something in stderr function errcho(){ >&2 echo $1 } # check if a binary can be found in the PATH # if not, warn and die function checkBinPresence(){ if [[ "`which $1`" == "" ]]; then errcho "$1 must be installed and in your PATH" exit 1 fi } # checking bowtie presence checkBinPresence bowtie checkBinPresence bowtie-build # now we launch the script and pass it all the arguments we received crossconta-detection.pl $@