commit 4ef4bc2308163f91361eed3e4006a53e8a033284
parent 5526fc7b5556b3a26f95d28e1b4942cb253a92bd
Author: kristapsdz <kristaps@bsd.lv>
Date: Mon, 9 Mar 2020 10:50:22 +0000
parent 5526fc7b5556b3a26f95d28e1b4942cb253a92bd
Author: kristapsdz <kristaps@bsd.lv>
Date: Mon, 9 Mar 2020 10:50:22 +0000
Check for required files.
1 file changed, 14 insertions(+), 0 deletions(-)
diff --git a/minci.sh b/minci.sh @@ -6,6 +6,7 @@ MAKE="make" API_SECRET= +DEP_BINS="mandoc pkg-config openssl git curl" NOOP= API_KEY= SERVER= @@ -61,6 +62,8 @@ do MAKE="$bsdmake" done < "$CONFIG" +DEP_BINS="$DEP_BINS $MAKE" + # Read the API secret from the configuration. while read -r ln @@ -107,6 +110,17 @@ echo "$0: using API key: $API_KEY" echo "$0: using API secret: $API_SECRET" echo "$0: using server: $SERVER" +for dep in $DEP_BINS +do + echo "$0: check binary dependency: $dep" + which "$dep" 2>/dev/null 1>&2 + if [ $? -ne 0 ] + then + echo "$0: binary dep not in PATH: $dep" 1>&2 + exit 1 + fi +done + # Check or create where we'll put our repositories. if [ ! -d "$STAGING" -a -z "$NOOP" ]
: nply/minci