usage () { echo "You must set a $1 !" echo "Usage:" echo " new_kresus.sh " exit 0 } if [ -z $1 ]; then usage "USER" elif [ -z $2 ]; then usage "PASSWORD" fi USER=$1 PASS=$2 git clone https://framagit.org/bnjbvr/kresus.git $USER.kresus.neodarz.net cd $USER.kresus.neodarz.net; npm install; npm install leveldown@1.5.0; ./scripts/build.sh htpasswd -Bb -c .htpasswd $USER $PASS