Code

Bash completion support for aliases
[git.git] / git-fetch.sh
index b15fc2b389f35e2b30b17eada4bcc711a12d2a11..7dc1f33687279812605c7b6f9ddc13478e143058 100755 (executable)
@@ -296,6 +296,7 @@ fetch_main () {
       # There are transports that can fetch only one head at a time...
       case "$remote" in
       http://* | https://* | ftp://*)
+         proto=`expr "$remote" : '\([^:]*\):'`
          if [ -n "$GIT_SSL_NO_VERIFY" ]; then
              curl_extra_args="-k"
          fi
@@ -319,7 +320,7 @@ fetch_main () {
          done
          expr "z$head" : "z$_x40\$" >/dev/null ||
              die "Failed to fetch $remote_name from $remote"
-         echo >&2 Fetching "$remote_name from $remote" using http
+         echo >&2 "Fetching $remote_name from $remote using $proto"
          git-http-fetch -v -a "$head" "$remote/" || exit
          ;;
       rsync://*)