0% found this document useful (0 votes)
49 views1 page

Installing Flutter On A Mac, and Running Your First Flutter App - Seth Ladd

This document summarizes the steps to install Flutter on a new Mac and run a demo Flutter app in under 10 minutes. The steps include cloning the Flutter SDK from GitHub, adding Flutter to the path, running flutter doctor to check dependencies, installing Android Studio for the Android SDK, creating and running a demo app on an Android emulator.

Uploaded by

George Pine
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
49 views1 page

Installing Flutter On A Mac, and Running Your First Flutter App - Seth Ladd

This document summarizes the steps to install Flutter on a new Mac and run a demo Flutter app in under 10 minutes. The steps include cloning the Flutter SDK from GitHub, adding Flutter to the path, running flutter doctor to check dependencies, installing Android Studio for the Android SDK, creating and running a demo app on an Android emulator.

Uploaded by

George Pine
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

!"#$%&'(( !"!#$%&''&()*+ ,-&.

/ %&''&(
Acceder a Medium con
0>C?$>?
Google
E)/$+/3*/)4

jorge pino
[email protected]

Continuar como jorge

)*+#',,-*.%/,0##"1%2*%'%3'45%'*(
10**-*.%6201%7-1+#%/,0##"1%'88
0)/1$2344 5)6$789$:;7< · 8$=>?$*)34

tldr: You can install Flutter on a new Mac, and run your first Flutter demo app,
in under 10 minutes (not counting download times :)

Flutter is a new way to rapidly build high-quality apps for iOS and Android.
If you’re new to mobile development, or looking for a faster way to build
apps, we recommend taking a look at Flutter.

Flutter’s Install guide has the complete instructions, if you are looking for
all the details. This post is not the official install guide, this is just my journey
installing on my new Mac. This post has the “short version” which worked
for me. This post assumes you have some knowledge of how to use Macs,
and assumes you are comfortable typing a few commands on the command
line.

This post assumes you have git installed.

!"#$#%"$&'(##")$*+,
Open a new terminal window

Type: git clone -b beta https://github.com/flutter/flutter.git

Wait for the SDK to clone onto your machine

Type: export PATH=$PWD/flutter/bin:$PATH , which adds flutter tool to


your path

Type: flutter doctor , which downloads additional dependencies

Wait for dependencies to download and install

Congrats, you now have the Flutter SDK on your Mac! Next, you need to get
a platform (in this case, Android) SDK.

!"#$#%"$-./)01/$*+,
You need either Android Studio or Xcode to run your demo. We’ll choose
Android Studio just to get started, which gives you the Android SDK and the
Android Emulator. You can install Xcode later if you’d like.

Download Android Studio from here, and then install it

Launch Android Studio, and accept all the defaults

Wait for Android Studio to download the Android SDK for you

Once you see the “Welcome to Android Studio” dialog, with “Start a new
Android Studio project”, go ahead and quit Android Studio

Go back to the Terminal (where you set your PATH), and type: flutter
doctor

If you see [✓] Android toolchain in the output, then you can move on!

For example:

If you don’t see [✓] Android toolchain, read the output for suggestions or
email [email protected].

2)"3#"$40()$51)6#$/"70$388
In the Terminal, type flutter create my_first_app

Note that a new my_first_app directory was created

2)"3#"$3.$-./)01/$97('3#0)
Your first demo app will run inside an emulator.

Open Android Studio

Choose “open existing project”

Select the my_first_app directory, which flutter create created for you

Using the Android Studio menus, select Tools > Android > AVD
Manager

Click “Create Virtual Device”

Choose Pixel 2, click Next

Click Download for Oreo and accept the license

Wait for the images and SDKs to finish downloading

Choose Oreo for the system image, and click Next

Accept the defaults, click Finish

:(.$#%"$97('3#0)
Now that you have an emulator (also known as a Virtual Device), you need
to launch it.

Click the green arrow under “Actions” in the “Your Virtual Devices”
window

Wait for the emulator to boot up

Once you see the Android desktop in the virtual device, go back to the
Terminal, ensure you are in the my_first_app directory, and type flutter
devices

If you see “Android SDK built for x86” in the list of devices, you are ready to
run your first app! If you do not see any devices listed, please email flutter-
[email protected]

-;;"8#$#%"$-./)01/$*+,$'1;".6"6
(apologies, because, yes, apparently we have to do this now :)

Go to Terminal, and type flutter doctor --android-licenses

:(.$40()$/"70$388
With the emulator running a virtual Android device, you can now run your
app!

In the Terminal, ensure you are in my_first_app directory, and type


flutter run

(Allow incoming network connections to the java process, if you see that
popup)

Wait for initial dependencies to download and configure

And… ta da! Your app is running on the emulator!

<3="$5(.$>1#%$&'(##")?
Some resources to get your started:

Step-by-step codelab

Building layouts tutorial

Adding interactivity tutorial

Follow @flutterio on Twitter

Join our mailing list

Ask questions on Stack Overflow

We can’t wait to see what you build with Flutter!

@:; 8

,?4*&>4 %'.//)*

@0)"$5)07$*"#%$A3// %&''&(

A*&4.6/$B3?3C)*$D$E&&C')$F&*$%.61+>39$3./1&*9$6&?F)*)?6)$&*C3?>G)*"$2&H)+
-34=>?/&?$3?4$-&3*4$C3=)+"

@0)"$&)07$@"/1(7

<1B%$&1=" *%0)#$1.#)0$#0 H%".$DIE$#0 -$+)"1/"'


>1#%$CD9E$F !)38%GA J(4$I.'1." !37"
I)*=>?$#313*&H>6 J>K>?C$L&?++&?$>?
20()6"6$50) *17('3#10.
>?$B3)+/*3' M1)$0/3*/.N
+"="'087".# *;)18#$O61.B
E00'6$K&0) P4#%0.
J"B1..")6$L 23?6)$P)>?+=>/1
M.#")7"/13#"N
L.3?$B&6/)G.=3O
%'&*)+$>?$M1)
0/3*/.N

&1)6#$2AM <0>$A0.B$+1/ H%4$3)" :"'3#10.3'$=6


-88'1;3#10. M#$E3Q"$R0($#0 5(.;#10.3' .0.U)"'3#10.3'
,')Q>+$M)1$>?$M1)
I="))1/" #"6#6$60$7(;% /3#3V36"6
0/3*/.N
*1.3#)3$<EEP '0.B")$#%3. 5*>)+$,.C.+/T?+
:"S("6#6T (.1#$#"6#6T
R3?3$2" S&??>)$061.'K>?$>?
I)*4$%&*$M)61

,-&./ U)'N 2)C3'

You might also like