The article directories
- flutter SDK
- Android Studio
- The simplest creation process
- Common commands
- In the real machine installation joint adjustment
flutter SDK
- Download the latest SDK from the official website
https://flutter.cn/docs/get-started/install/windows
- Unzip to the directory you need to install, and unzip to install
- Configuring environment variables (important)
- Your own path \flutter\bin
- export PUB_HOSTED_URL = pub.flutter-io.cn
- export FLUTTER_STORAGE_BASE_URL = storage.flutter-io.cn
- Configure the environment variable for ANDROID_HOME
- Choose your own path \androidSDK
Dart SDK includes flutter/bin/cache/dart-sdk
Check whether the environment is set up successfully
Terminal runs the Flutter Doctor
Android Studio
- Official website to download
https://developer.android.google.cn/studio
- Follow the installation wizard to install it. The agent Settings can be selected automatically or manually
- After the installation is complete, install the corresponding Flutter and DART plug-ins
- Create a Flutter application to create virtual devices and debug them on your phone
The simplest creation process
- Install the environment according to the official website
- flutter create
- flutter run
- A Chrome page displays automatically
Common commands
The command | role |
---|---|
flutter | List all commands |
flutter help | Get help information |
flutter –version | View the current FLUTTER and DART versions |
flutter upgrade | Upgrade flutter |
flutter doctor [-v] | Check development environment status |
– | – |
flutter create project_name | Create a Flutter project |
flutter pub/packages get | Install dependencies |
flutter packages upgrade | Upgrade depend on |
Flutter run [-d Device name] | Runs to the specified device |
flutter clean | Clear the Build directory |
– | – |
flutter emulators | Lists available emulators |
flutter devices | List available equipment |
open -a Simulator | Open up an emulator |
flutter emulators –launch apple_ios_simulator | Open up an emulator |
– | – |
Flutter build apk [– release –target-platform android-arm64] | Generates apK packages for the specified schema |
flutter build ios | The iOS packaging step does not generate IPA files, you need to use Xcode packaging |
flutter install | Install app to device |
flutter run –release | Release testing requires a connection to a real machine to debug. |
In the real machine installation joint adjustment
Other domestic need to set the mirror, otherwise update download failure, refer to
Because Chinese website
The Dart Chinese website
If you have any questions, please leave a message in the comment section or follow my wechat public number: Front juvenile Wang if this article is helpful to you, welcome to three links with one button, thank you