Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error: RPC failed; HTTP 302 curl 22 The requested URL returned error: 302

When I executed the git clone command, I got the the following error.

Error: RPC failed; HTTP 302 curl 22 The requested URL returned error: 302

The error always happened in case of Ubuntu 18.04 or 20.04, but The error didn't happen in case of Ubuntu 16.04.

I don't know the difference Ubuntu 16.04 and 18.04/20.04.

Could you please give me some advice me?

like image 509
May Avatar asked Sep 06 '25 21:09

May


1 Answers

git config --global http.followRedirects true

I got the solution from: https://blog.csdn.net/weixin_46027808/article/details/133032114

To summarize the solution, the 302 error means that the resource has been temporarily moved to a new location. The server will give a new URL, and the client is expected to make a request again to the new URL.

like image 134
Anindya Gautam Avatar answered Sep 09 '25 20:09

Anindya Gautam