问题1:
尝试指令:
flutter packages pub publish --server=https://pub.dartlang.org
问题2:
问题1解决后,进入验证身份,点击终端显示的链接,跳转到google验证,记得这里要科** 学上网,点击确定认证后,发现一直卡在下图问题,或者是一直上传不上去超时等情况。
尝试解决方案:
- 首先查看科** 学上网的代理 我这里使用的是** 软件,如下图点击复制出来**端口号
粘贴出来
export https_proxy=http://127.0.0.1:7890
http_proxy=http://127.0.0.1:7890
all_proxy=socks5://127.0.0.1:7890
根据粘贴出来的知道***端口号为:7890 然后把下面命令端口号换成你的端口号,我这里是7890
export https_proxy=http://127.0.0.1:7890
export http_proxy=http://127.0.0.1:7890
set https_proxy=https://127.0.0.1:7890
set http_proxy=http://127.0.0.1:7890
复制上面的指令在android studio终端terminal中执行。然后再重新执行发布命令。
flutter packages pub publish --server=https://pub.dartlang.org
执行完成后