DEV Community

Cover image for Flutter set up for android on mac
Dhiraj kumar Nayak
Dhiraj kumar Nayak

Posted on

Flutter set up for android on mac

Make sure you have installed JDK and android-studio.

First We have to download flutter Manually unzipping the folder on desktop.Then place the flutter file inside /home creating a new directory /developer and inside the folder, we have to place the flutter file. you should do manually opening finder.

Second thing You should do

then after placing flutter file inside the /User/developer you have to configure your flutter so you need to
edit bash_profile so you need to add the command changes the flutter file location then change it to what is necessary to make.

open up The terminal then place the command and place cd ~/ it will take you to the home directory.

then vi ~/.bash_profile it will open up the text editor you just enter e to edit the file

Press 'i' to insert the file then add a line inside bash_profile

 #export
 export PATH="$PATH:/Users/thedkn/Developer/flutter/bin"

After configuring the path variable you enter ESC key then
Press Shift-z-z to save and exit.

Flutter Set up on the visual studio code

you should have to download the flutter plugin 1st one is the flutter then install it then after it will ask you for
install some Extention

  1. Flutter
  2. Awesome Flutter Snippets

after the installation completed open up terminal go to cd Desktop then a project by flutter create project_name the project_name is according to your project make sure project name is always in small latter.

Run Project

To Run, the project we have to check the flutter is successfully installed or not we have to check in the terminal by command flutter doctor.

opening our project on vs code simply go to Run & Debug then select an emulator installed and it automatically runs your project on Emulator

Fix the common problems arise in Development

A most common problem arises due to the app is compiled wrongly so before you Run delete the build folder which is inside the root of your project.

hope you find it valuable. thank you!

Latest comments (0)