git config --global http.proxy http://localhost:port
git config --global https.proxy https://localhost:port
其中,localhost为服务器地址,port为服务端口

实例

这里以设置本地代理服务127.0.0.1:1080为例。
git config --global http.proxy http://127.0.0.1:1080
git config --global https.proxy https://127.0.0.1:1080

 

 

相关文章:

  • 2022-01-07
  • 2021-06-10
  • 2021-07-19
  • 2021-10-20
  • 2021-08-20
  • 2022-12-23
  • 2021-10-29
猜你喜欢
  • 2021-10-18
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-10-06
  • 2021-12-04
  • 2021-11-20
相关资源
相似解决方案