new clone fix for repository and remote host options
This commit is contained in:
@@ -15,9 +15,17 @@ BASE_FOLDER=$(dirname "$(readlink -f "$0")")"/";
|
||||
# shellcheck source=init.sh
|
||||
. "${BASE_FOLDER}init.sh";
|
||||
|
||||
if [ -z "${REPOSITORY}" ]; then
|
||||
echo "[!] Must set a repository path";
|
||||
error=1;
|
||||
fi;
|
||||
if [ -z "${REMOTE_HOST}" ]; then
|
||||
echo "[!] Must set a remote host for the repository";
|
||||
exit;
|
||||
error=1;
|
||||
fi;
|
||||
# if we have an ":" in the repository, split by it and replace it with the remote host
|
||||
if [[ "${REPOSITORY}" == *":"* ]]; then
|
||||
REPOSITORY=$(echo "${REPOSITORY}" | cut -d ":" -f 2);
|
||||
fi;
|
||||
|
||||
error=0
|
||||
|
||||
Reference in New Issue
Block a user