Android comments edit

If you’ve been watching the news out of Google I/O today, you’ll have heard about Android Studio.  Android Studio is a new IDE based off of NetBean’s IntelliJ IDE for Android development.  This is super exciting to many Android developers because many people are using Eclipse and Eclipse is generally pretty terrible.  Plus, an IDE made by the people that are making the Android OS / SDK is pretty exciting.  As soon as they made Android Studio available to download, I went and grabbed it and installed it.  One of the first things I noticed once I installed it was that when I went to create a project, not all of the SDK versions that I already had installed were showing up as SDK choices.  This made me realize that at no point in the install process was I asked where my install of the Android SDK was at.  The reason for that is that Android Studio installs it’s own version of the SDK in it’s own app folder.  On OS X, if you navigate to /Applications/Android Studio.app/sdk, you’ll see the Android SDK installed by Android Studio.  This might be fine if I was ready to commit entirely to Android Studio, but with it being at v0.1, I’m not quite ready to make that jump.  What I really wanted to do was point Android Studio at the same version of the SDK I was using elsewhere.

Changing the SDK

The first place I looked for changing this was in the Preferences section.  Unfortunately, I couldn’t find anything here.  I looked around in some of the other menus and didn’t find anything obvious (Tools has an Android submenu, but it’s just for launching the AVD Manager, SDK Manager, Monitor, or enabling / disabling ADB Integration).  Fortunately I kept looking and stumbled upon the File –> Project Structure menu.  After opening this, I found something that referenced the SDK:

Project Structure

Clicking the Edit button Takes you to the SDKs area on the left which includes the ability to change the Android SDK Home Path:

Android SDK Home Path

Once we change this, we’re set to use our previously installed SDK.  But wait, there’s more!

SDK Updates

Before you do this, you probably want to make sure you have the latest updates to the SDK.  Open the SDK manager (the original SDK install) which you should be able to open by running SDK_PATH/tools/android.  Once you’ve run this, make sure you don’t have any updates available for Android SDK Tools, Android SDK Platform-Tools, and Android SDK Build-tools.  Android Studio uses a new build engine so if you try to change your SDK home path and create a new project without getting this update, it won’t work!

Good luck and enjoy playing with Android Studio.  The team has said they’re hoping to do weekly updates and Android Studio is set up to check for updates on it’s own so hopefully any issues we run into should get fixed fast.


Chris Risner