Hi Guys,
I have mac machine, so I am going to tell you how to install flutter in MAC machine.
- Download Flutter Stable SDK version and save in you machine which is required while setting the IDE. I prefer it to be saved in 'Documents' folder.
- In my case I have saved it in 'Documents/SDKs'
- Unzip the Flutter Stable SDK zip file
- Open terminal and type the following commands
- $ cd ~/Documents/SDKs/flutter
- $ export PATH="$PATH:`pwd`/flutter/bin"
- The Step 3 is for the particular terminal window only, to make it permanent follow the below process in the terminal
- $ echo $SHELL
- The above command will tell you what kind of shell is your macbook is. In my case it is Z shell
- $ export PATH="$PATH:[PATH_OF_FLUTTER_GIT_DIRECTORY]/bin"
- To verify use command $ echo $PATH
- To verify the flutter is working use the command $which flutter
- The above command should provide with the path.
- Once the SDK setup is completed, we have to setup the IDE. Below is the process to setup.
- Download the xcode and command line tools to run on iOS device/ Simulator.
- To run on Android device, follow the below process.
- Download and install Android studio.
- Once Android studio installed, go to the Android studio setup wizard and install
- Latest Android SDK
- Latest Android SDK command line tools
- Latest Android SDK build tools
- Open Preference from the Android studio, go to Plugins and search for "Flutter". If it is not installed, install it.
- Similarly, install Dart and Kotlin.
- Once the IDE and SDK setup is completed, check what is the version of JAVA that is active. For flutter to work JAVA 8 should be active. If Java 8 is not installed, install Java 8 and do the following
- Open terminal and follow the commands
- $ nano ~/.zhenv
- Z Shell file will opened and enter the below text
- export JAVA_HOME=$(/usr/libexec/java_home -v1.8)
- Finally, run the command in the terminal $ flutter doctor
- If you get any error related to "Android license status unknown", Do the following
- In terminal, type the command $ flutter doctor --android-licenses
- Then it ask to accept the licenses, please accept and continue.