#!/bin/sh

act=${1:-uninstall}
echoG(){ 
    echo -e "\e[32m$*\e[0m"
}

prepare(){
	echoG '---- download   tgz ----'
	cd /opt/
	echoG '---- decompress tgz ----'
	cd php7
}

case "$act" in
	'install')
		prepare
		echoG '---- install    tgz ----'
		( . php7_script.sh; install )
	;;
	'uninstall')
		prepare
		echoG '---- uninstall tgz ----'
		( . php7_script.sh; uninstall )
	;;
	*)
		echo 'unkown act'
esac

