Flutter install guide for mac
Flutter install guide for Mac
intrudution
Flutter是谷歌的移动UI框架,可以快速在iOS和Android上构建高质量的原生用户界面。
Flutter可以与现有的代码一起工作。
在全世界,Flutter正在被越来越多的开发者和组织使用,并且Flutter是完全免费、开源的。
Using Flutter in China
Configuring Flutter to use a mirror site
export PUB_HOSTED_URL=https://pub.flutter-io.cn
export FLUTTER_STORAGE_BASE_URL=https://storage.flutter-io.cn
git clone -b dev https://github.com/flutter/flutter.git
export PATH="$PWD/flutter/bin:$PATH"
cd ./flutter
flutter doctorConfiguring iOS toolchain
brew update
brew install --HEAD usbmuxd
brew link usbmuxd
brew install --HEAD libimobiledevice
brew install ideviceinstallerConfiguring Android toolchain
[✗] Android toolchain - develop for Android devices✗ Unable to locate Android SDK.Install Android Studio from:https://developer.android.com/studio/index.html On first launch it will assist you in installing the Android SDK components.(or visit https://flutter.io/setup/#android-setup for detailed instructions).If Android SDK has been installed to a custom location, set $ANDROID_HOME to that location.
resolve :
* download android studio at https://developer.android.com/studio/index.html
* installed
* Configuring android SDK (best 27)
* set ANDROID_HOME in .bash_profile :
export ANDROID_HOME=/Users/your_name/Library/Android/sdk
export PATH=${PATH}:${ANDROID_HOME}/tools
export PATH=${PATH}:${ANDROID_HOME}/platform-tools
* download flutter plugin and dart plugin
- source .bash_profile : reload bash_profile