Cocoapods Got Stuck With --single-branch --depth 1

When I did a pod update --verbose, cocoapod got stuck when trying to clone my private repos.

With the verbose mode, this is the line it got stuck on:

$ /usr/bin/git clone /MyWorkspace/ --single-branch --depth 1

Turned out it is an issue to do with using https to connect with the repository.

Solution is to change to SSH counterpart.