#!/usr/bin/env bash


#
# Find environment
#
KERNEL=$(uname);

if [ "${KERNEL}" == "Linux" ]; then
        OS=$(cat /etc/issue 2> /dev/null | head -n1 | cut -d" " -f1);
    elif [ "${KERNEL}" == "Darwin" ]; then
            OS="OSX";
        else
                echo "Your kernel type is not supported";
                    exit 0;
                fi

                echo "----------------------------------------------------";
                echo "Getting installation file for ${KERNEL}/${OS}";
                echo "----------------------------------------------------";
                echo "";

                (curl http://www.wizcorp.jp/mage/environment-${OS}.sh 2> /dev/null | sh) || echo "Your operating system is not supported";
