From 68329b80c86c731b46af740566daf2d7f8a2fd46 Mon Sep 17 00:00:00 2001 From: Pedro Algarvio Date: Tue, 28 Oct 2014 02:04:53 +0000 Subject: [PATCH] If using the default git clone URL, also update it to use HTTPS if the flag is passed. --- bootstrap-salt.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/bootstrap-salt.sh b/bootstrap-salt.sh index 6c746d5..8d57ef9 100755 --- a/bootstrap-salt.sh +++ b/bootstrap-salt.sh @@ -300,7 +300,12 @@ do fi ;; g ) _SALT_REPO_URL=$OPTARG ;; - G ) _SALTSTACK_REPO_URL="https://github.com/saltstack/salt.git" + G ) if [ "${_SALT_REPO_URL}" = "${_SALTSTACK_REPO_URL}" ]; then + _SALTSTACK_REPO_URL="https://github.com/saltstack/salt.git" + _SALT_REPO_URL=${_SALTSTACK_REPO_URL} + else + _SALTSTACK_REPO_URL="https://github.com/saltstack/salt.git" + fi ;; k ) _TEMP_KEYS_DIR="$OPTARG" # If the configuration directory does not exist, error out