From: Aurelien Bompard Date: Sun, 28 Oct 2007 17:47:30 +0000 (+0100) Subject: honor the http.sslVerify option in shell scripts X-Git-Tag: v1.5.3.5~15 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=1c1f79a1e44547d039e7bf94d9aaadd3fae007d1;p=git.git honor the http.sslVerify option in shell scripts Signed-off-by: Aurélien Bompard Signed-off-by: Junio C Hamano --- diff --git a/git-clone.sh b/git-clone.sh index 5e582fe24..0ea3c24f5 100755 --- a/git-clone.sh +++ b/git-clone.sh @@ -28,7 +28,8 @@ get_repo_base() { ) 2>/dev/null } -if [ -n "$GIT_SSL_NO_VERIFY" ]; then +if [ -n "$GIT_SSL_NO_VERIFY" -o \ + "`git config --bool http.sslVerify`" = false ]; then curl_extra_args="-k" fi diff --git a/git-ls-remote.sh b/git-ls-remote.sh index d56cf92eb..fec70bbf8 100755 --- a/git-ls-remote.sh +++ b/git-ls-remote.sh @@ -54,9 +54,10 @@ tmpdir=$tmp-d case "$peek_repo" in http://* | https://* | ftp://* ) - if [ -n "$GIT_SSL_NO_VERIFY" ]; then - curl_extra_args="-k" - fi + if [ -n "$GIT_SSL_NO_VERIFY" -o \ + "`git config --bool http.sslVerify`" = false ]; then + curl_extra_args="-k" + fi if [ -n "$GIT_CURL_FTP_NO_EPSV" -o \ "`git config --bool http.noEPSV`" = true ]; then curl_extra_args="${curl_extra_args} --disable-epsv"