#!/usr/bin/env bash echo -n 'Have you connected to the open vpn [y or n]?' read -r connectedOpenVPN if [ "$connectedOpenVPN" == 'n' ]; then echo 'Connect to the open vpn'; exit; fi echo -n 'Have you configured git and added ssh key to Git Hub account [y or n]?' read -r configuredGit if [ "$configuredGit" == 'n' ]; then echo 'Configure your git and Add ssh key to Git Hub account before proceeding'; exit; fi echo -n 'Do you wish to clone all the smiths project repositories [y or n]?' read -r cloneRepo if [ "$cloneRepo" == 'y' ]; then echo -n 'Enter full path where you want to clone the repo (e.g. /home/{yourUsername}/projects:' read -r projectDir if [ -d "$projectDir" ]; then echo "Directory $projectDir already exists. Please specify new location";exit; fi mkdir -p $projectDir echo "$projectDir directory created" echo "Changing directory to $projectDir" cd $projectDir cd touch init.txt echo '======== Cloning Repo ========' git clone [email protected]:repo/name.git echo '======== Cloning Repo ========' git clone [email protected]:repo/name.git fi