- Linux 或 Mac
export PUB_HOSTED_URL=https://pub.flutter-io.cn
export FLUTTER_STORAGE_BASE_URL=https://storage.flutter-io.cn
- Windows
新增两个环境变量即可:
PUB_HOSTED_URL ===== https://pub.flutter-io.cn
FLUTTER_STORAGE_BASE_URL ===== https://storage.flutter-io.cn
执行一下 flutter doctor -v 命令。
然后再执行 flutter packages get 即可。
网友评论