mac fool installation flutter

According to documentation https://flutterchina.club/setup-macos/

If you can not over the wall, I've got one on Baidu cloud disk, there is a need to download
link: https://pan.baidu.com/s/1j66GzFWypthf75JmAFF40w extraction code: vmhw copy the contents of this open Baidu network disk phone App, the operation more convenient oh


Question 1:

// 下载下来的 flutter 安装的目录
cd ~/development  
 // ~/Downloads 你要安装的目录 
unzip ~/Downloads/flutter_macos_v0.5.1-beta.zip 
//默认当前目录则为 
unzip flutter_macos_v0.5.1-beta.zip  // flutter_macos_v0.5.1-beta.zip 下载下来的版本,也就是你的名称

//然后执行 
export PATH=`pwd`/flutter/bin:$PATH

//再执行 
flutter doctor

Focus here, you'll run into a bunch of problems


Question 2

Android toolchain - develop for Android devices
1684275-965bad9ec61ee483.png
image.png

Solution

  1. Installation android studio
    After installing, then perform
flutter doctor

There are problems, then open android studio, installation sdk, the installation process may prompt pop

mac Unable to access Android SDK add-on list

Sometimes more than a few canceled installed on their own, so I do not know why. But the Internet was posted answers
https://www.jianshu.com/p/dcf5675c8a9e

  • Go to the application, find the Android Studio, right click -> Show Package Contents -> Contents-> bin, locate the file idea.properties, use the Text tool to open
  • Add idea.properties file at the end of a line: disable.android.first.run = true, and then save the file .
  • After closing the Android Studio is restarted, you can enter the interface .

This time it went to a cup of tea, slowly install sdk ...


carried out

flutter doctor

Now the above problem has basically been resolved


Question 3

1684275-0310c844e2d52d8c.png
Pictures .png

Follow the prompts in order to execute the command below


Question 4

1684275-b24580d136407a29.png
1.png
solution:
  • Install two plug-ins:
    Flutter plugin: Support Flutter development workflow (run, debug, thermal overload, etc.).
    Dart plug-in: Provides code analysis (for authentication when entering the code, the code completion etc.).
  • Start Android Studio.
    Open the Plug-in Preferences (Preferences> Plugins).
    Select Browse repositories ..., select Flutter plug-in and click install.
    Reboot Android Studio plug-ins to take effect.

Question 5

1684275-6cb3739943601593.png
2.png

This problem is solved very good, open the link in the figure, in accordance with the guidelines, to open the Visual Studio Code, if the application is not to install it, open the link prompts to install


Question 6

Compiler configuration problems arise, I am here with the visual studio code

Installation VS Code
  • Code VS , install version 1.20.1 or later.
Flutter plug-in installation
  1. Start VS Code
  2. Call View> Command Palette ...
  3. Enter 'install', then choose Extensions: the Install the Extension Action
  4. In the search box, enter flutter, choose 'Flutter' in the search results list, and then click Install
  5. Selecting 'OK' to restart the VS Code
By Flutter Doctor verify your settings
  1. Call View> Command Palette ...
  2. Enter 'doctor', select 'Flutter: Flutter Doctor the Run' Action
  3. See if "OUTPUT" output window of a problem

According to the same course, the problem arises


1684275-a45781bbf67e2922.png
image.png
Solution:

Click Locate SDK, load your local installation flutter path can be solved.

Reproduced in: https: //www.jianshu.com/p/1a2ff038c70b

Guess you like

Origin blog.csdn.net/weixin_33694620/article/details/91090794