You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Windows 11 PowerShell执行SpotX脚本时遇连接超时错误

解决PowerShell连接raw.githubusercontent.com失败的问题

原因分析与修复步骤

  • 验证网络连通性
    在PowerShell中执行命令:Test-NetConnection raw.githubusercontent.com -Port 443,若返回TcpTestSucceeded: False,说明网络层面无法连通,多是DNS污染或区域网络限制导致。

  • 更换公共DNS服务器

    1. 打开「设置」→「网络和互联网」→对应网络(Wi-Fi/以太网)→「硬件属性」
    2. 找到「DNS服务器分配」,选择「手动」,开启IPv4,添加8.8.8.8、8.8.4.4(谷歌DNS)或1.1.1.1、1.0.0.1(Cloudflare DNS)
    3. 保存设置后重启网络,再尝试执行原脚本
  • 手动下载脚本执行
    若无法直接从GitHub下载,可通过其他可访问GitHub的设备下载Install.ps1文件,传到你的笔记本:

    1. 打开PowerShell,切换到脚本所在目录(例:cd C:\Downloads)
    2. 先执行[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
    3. 再执行.\Install.ps1 -new_theme
  • 配置网络代理(若需)
    若网络需通过代理访问外部,先在PowerShell中设置代理:
    执行netsh winhttp set proxy proxy-server="http://你的代理地址:端口",脚本执行完成后可通过netsh winhttp reset proxy重置代理设置


内容的提问来源于stack exchange,提问作者Yashasvi Jaiswal

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.07.20 13:42:04