解决Github下载速度慢的问题

1. 方式一

  • 先把hosts文件先复制一份到其他文件夹下,以免造成不小心改动出现的后果
  • 在C盘的C:\Windows\System32\drivers\etc 下的hosts文件
  • 用编辑器打开后,在末尾处添加访问如下的两个网站所返回的两个IP
java 复制代码
https://github.com.ipaddress.com/
http://github.global.ssl.fastly.net.ipaddress.com 
  • 在hosts文件添加如下:
vbnet 复制代码
# github
xxx.xxx.xxx.xxx github.com 

xxx.xxx.xxx.xxx github.global.ssl.fastly.net

其实上面两个ip就是GitHub网站所处的IP地址和服务器的位置

  • 添加完成之后,接着打开cmd命令,刷新DNS的权限即可访问GitHub官网
bash 复制代码
ipconfig /flushdns

2. 方式二

bash 复制代码
xxx.xxx.xxx.xxx assets-cdn.github.com
相关推荐
夕阳染色的坡道5 小时前
Github 管理项目常用的基本命令
github
CoderJia程序员甲5 小时前
GitHub 热榜项目 - 日榜(2025-10-31)
ai·开源·llm·github
2501_9387900714 小时前
从 0 到 1:解决 VsCode 远程连服务器后 Github Copilot 无法使用问题
服务器·vscode·github
松垮的屁兜16 小时前
【gitlab】新建项目库并提交初始框架
gitlab·github
2501_9387912219 小时前
VsCode 远程模式 + 服务器:Github Copilot 安装后无法触发?原因解析
服务器·vscode·github
QmDeve20 小时前
Android 使用液态玻璃(LiquidGlass)效果,真实的折射和色散效果
android·github
@LetsTGBot搜索引擎机器人21 小时前
从零打造 Telegram 中文生态:界面汉化 + 中文Bot + @letstgbot 搜索引擎整合实战
开发语言·python·搜索引擎·github·全文检索
AmazingKO21 小时前
推送报错403怎么办?vscode推送项目到github
chatgpt·github·visual studio code·竹相左边
油泼辣子多加1 天前
2025年10月31日Github流行趋势
github