1. 修改本地hosts文件

用编辑工具打开
windows系统的hosts文件的位置如下:C:\Windows\System32\drivers\etc\hosts
mac/linux系统的hosts文件的位置如下:/etc/hosts

2. 增加http://github.global.ssl.fastly.net和http://github.com的映射

获取Github相关网站的ip
访问https://www.ipaddress.com,
分别输入github.global.ssl.fastly.net和github.com,查询ip地址
下面是我的配置

192.30.253.113		Build software better, together
151.101.185.194		github.global.ssl.fastly.net

 

 

3.刷新dns
使用win+R输入cmd进入控制台,输入指令 ipconfig /flushdns 刷新DNS

 

posted on 2022-02-27 13:07  京鸿一瞥  阅读(246)  评论(0编辑  收藏  举报