This post demonstrates how to add an Android SDK
in IntelliJ IDEA
.
Requirements
Stuff used in this post.
- Windows 10 Enterprise
- IntelliJ IDEA Ultimate 2016.3
- Java 8
- Android SDK Tools for Windows
We will not use Android Studio for this post.
The Problem
So we want to create an Android
project in our new machine using IntelliJ IDEA
and we see this:
[wp_ad_camp_5]
To fix this, we need to download an Android SDK
.
Download SDK
Go to https://devloper.android.com/studio/index.html.
Since we are not using Android Studio
, just scroll down until the Get just the command line tools section.
Click to download the SDK Tools
package for Windows
.
Save the zip file to some directory. For example:
[wp_ad_camp_4]
Extract the zip file so that everything is extracted to the current directory.
Use SDK Manager
Next we need to download the actual Android SDK
using the SDK Manager
.
1. Open Windows Command Line
If JAVA_HOME
is not set, we can do that in the current window.
[wp_ad_camp_3]
Then, change directory to tools\bin
Then, we use the sdkmanager.bat
.
For example:
1 | sdkmanager "platforms;android-26" |
Then, the Terms and Conditions
is displayed. Just scroll to down until you reach the end.
Choose y
and press Enter
. The SDK Manager
will now download the SDK
. The current directory will then have 2 new folders.
Configure IntelliJ IDEA
Finally, we configure IntelliJ
by adding an Android SDK
.
[wp_ad_camp_2]
To select the home directory for Android SDK
, navigate to our android_sdk
directory.
NOTE: Simply copy-and-pasting the path may not work.
Click Ok
.
Click Ok
.
[wp_ad_camp_1]
Create an Android Project anew
Thanks so much, great!
You are welcome! 🙂
Thank you so Much!!! This helped