github for window 中 git shell 设置代理方法和解决ssl证书错误的问题

github for window 中 git shell 设置代理方法和解决ssl证书错误的问题 感谢作者 --> 原文链接

    因为国内特殊的网络环境,所以用github for windows,在使用git shell的clone命令是会出现这样的情况

git clone https://code.google.com/p/android-os-monitor.osmonitor/ Cloning into android-os-monitor.osmonitor...

error: Unknown SSL protocol error in connection to code.google.com:443 while accessinghttps://code.google.com/p/android-os-monitor.osmonitor/info/refs

 

    那么解决这个问题的办法就是用代理方式去访问了,这里的解决方法中用的是goagent,是在使用goagent的前提下才能执行下面的操作。

    打开goagent软件,会看到 listen Address:127.0.0.1:8087,那么在git shell中执行的命令就是:

git config --global http.proxy "127.0.0.1:8087"

    这个问题可以解决了,但是遇到了另一个问题:

D:\GitHub> git clone https://github.com/subying/jsbook.git Cloning into 'jsbook'...

fatal: unable to access 'https://github.com/subying/jsbook.git/': SSL certificate problem: unable to get local issuer certificate

     提示SSL证书错误。后面用谷歌搜索了一下,发现说这个错误并不重要是系统证书的问题,系统判断到这个行为会造成不良影响,所以进行了阻止,只要设置跳过SSL证书验证就可以了,那么用命令 :

git config --global http.sslVerify false

 

转载于:https://www.cnblogs.com/amou/p/9458359.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值