mac install flutter

1, ladders

2, installation brew

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)”

3, download flutter

https://flutter.io/setup-macos/

4, configure the environment variables

vim ~ / .bash_profile
 
Input: Export the PATH = "/ bin Flutter Path": $ the PATH
 
: WQ (exit) 

Enter

5, environment variables to take effect

source ~/.bash_profile

6, detects whether the installation is complete

flutter -h

7, assay development environment

flutter doctor

8, install the studio 

    Before Installation To install the Java 
    HTTP: // www.android-studio.org/

9, the command input terminal

brew install --HEAD libimobiledevice

brew install ideviceinstaller

brew install ios-deploy

brew install cocoapods

pod setup

10, start andriod studio

plugins in search flutter 

download flutter

11, create a flutter project

Open Studio Andriod 

Start A new new Flutter Project (very slow) 

Select flutter application 

installation avd Virtual Machine 

Tool - avd Manager 

the Create Virtual Device 

Nexus 5X Andriod 9 

the Next

12、debug

Given 

view swap file in android build.gradle directory project 

Maven {URL 'https://maven.aliyun.com/repository/google' } 
        Maven {URL 'https://maven.aliyun.com/repository/jcenter ' } 
        Maven {URL' HTTP: // maven.aliyun.com/nexus/content/groups/public '} 

 

\ Flutter \ Flutter \ Packages \ flutter_tools \ Gradle 

 

Maven {URL ' HTTPS: // m aven.aliyun.com/ Repository / Google ' } 
        Maven {URL ' https://maven.aliyun.com/repository/jcenter ' } 
        Maven {URL' HTTP: // maven.aliyun.com/nexus/content/groups/public '}

13, the configuration vscode

vscode -> View -> Command Panel -> Flutter: new new Project -> Enter a project name 
click no device
flutter create app-name 
found main.dart file, click on the bottom right of the device vscode

 

Guess you like

Origin www.cnblogs.com/shui1993/p/11128918.html