Setup the development environment
Flutter development environment to build more cumbersome, any failure will result in a final step to build the environment can not be completed. Flutter support three environments: Windows, MacOS and Linux. Here we mainly on Windows and MacOS environment to build.
1.2.1 Windows environment to build
1. Mirroring
First, solve network problems. Environment to build process requires a lot of resources to download a file, when a resource is not up to date, it may report a variety of errors. Flutter in-country visit may sometimes be limited, Flutter official build a temporary image for the Chinese developers, the following environment variables can be added to the user environment variables:
export PUB_HOSTED_URL=https://pub.flutter-io.cn
export FLUTTER_STORAGE_BASE_URL=https://storage.flutter-io.cn