electron打包报错了,尝试了多个方案没有解决,种种在git上找到了解决方案,记录一下,说不定大家也会遇到;
打包报错:
Get "npmmirror.com/mirrors/ele…": proxyconnect tcp:dial tcp:0:connectex:The requested address is not valid in its context.
gitHub用户提供解决方案
亲测可用
npm config delete proxy
npm config delete https-proxy
npm config delete noproxy
手动下载这个包,放到以下路径
没有试过
Linux: $XDG_CACHE_HOME or ~/.cache/electron/
macOS: ~/Library/Caches/electron/
Windows: $LOCALAPPDATA/electron/Cache or ~/AppData/Local/electron/Cache/