Monday 9 January 2017

Set ANDROID_HOME and Path Environment Variables For SDK In Windows


Set ANDROID_HOME Variable

After installation of different packages, You need to set ANDROID_HOME and path environment variables. Follow the steps given bellow to set it.
  • Open "Environment Variables" dialog from win start menu -> Right click on My Computer -> Select properties -> Advanced system settings -> Environment Variables button from Advanced tab. 
  • Click on New button under User Variable table. It will open New User Variable dialog.
  • Set Variable Name = ANDROID_HOME and Variable value = E:\SDK (Path of SDK folder). Path can be different for you as per your SDK folder location as described in previous post.
  • Click on OK button to close New User Variable dialog as shown in bellow image.
ANDROID_HOME

Set Path Variables
  • Open SDK Folder from E: drive.
  • You will find "tools" and "platform-tools" folders inside SDK folder.
  • Copy path of both these folders. e.g. E:\SDK\tools and E:\SDK\platform-tools\
  • Open "Environment Variables" dialog as described above.
  • Locate Path variable line under System Variables table.
  • Edit Path variable by clicking on Edit button. It will open Edit  System Variables dialog.
  • Append "tools" and "platform-tools" folder's full path at the end of line as shown in bellow image. e.g. ;E:\SDK\tools;E:\SDK\platform-tools\;
set ANDROID_HOME

  • Now close all dialog by clicking on OK buttons of all opened dialog as shown in above image.
Verify Android Is Installed And Configured Properly
To check if android is configured properly or not,
  • Open command prompt.
  • Type command android as shown in bellow image.
  • It will open Android SDK Manager dialog as shown in bellow image.
Verify Android Is Installed


That means android is configured properly in your system.

Now ANDROID_HOME and Path Environment Variables are set for android SDK in windows environment. So android environment is configured and ready to use with appium to execute software automation tests. Next post will describe you how to integrate SDK with eclipse using Eclipse ADT Plugin to use android SDK with eclipse.

No comments:

Post a Comment