How to Setup Flutter in Android Studio – Linux
- Download Android Studio – https://developer.android.com/studio
- Get the Flutter SDK – https://flutter.dev/docs/get-started/install/linux
- Learn more about Android Studio – https://developer.android.com/studio/intro/
Step 1 : Get the Flutter SDK
1 Download the following installation bundle to get the latest stable release of the Flutter SDK:
2 Download SDK and extract downloaded file, just double click on that. and just copy extracted folder and paste it to your desired location (for example, Documents\flutter).
Step 2 : Update your path
Important:
Path variable needs to be updated to access “flutter” command from terminal. you can just update path variable for current terminal window only. and if you want to access flutter commands from anywhere in terminal, we need to update SDK path permanently.
You’ll probably want to update this variable permanently, so you can run flutter
commands in any terminal session. To update PATH variable, we need to open terminal.
export PATH="$PATH:[PATH_TO_FLUTTER_GIT_DIRECTORY]/flutter/bin"
- Run
source $HOME/.
to refresh the current window, or open a new terminal window to automatically source the file. - Verify that the
flutter/bin
directory is now in your PATH by running:
echo $PATH
Verify that the flutter
command is available by running:
which flutter
You are now ready to run Flutter commands in the Flutter Console!