#!/usr/bin/env bash
OSTYPE=$(uname -s)
# make sure bash is at least version 4 (includes associative arrays)
if [[ $OSTYPE == "Darwin" ]]; then
    [[ ${BASH_VERSINFO[0]} -ge 4 ]] || {
        echo "WARNING: pipeline requires at least bash version 4 (associative arrays)"
        echo "Use homebrew to install a newer version."
        exit 0
    }
else
    [[ ${BASH_VERSINFO[0]} -ge 4 ]] || { echo "FATAL: pipeline requires at least bash version 4 (associative arrays)" 1>&2; exit 255; }
fi
