I opened the
/etc/environment and added the line
ANDROID_SDK_HOME="/home/tom/android-sdk" but I tried
echo $ANDROID_SDK_HOME but displayed nothing. I have
JAVA_HOME in the same
/etc/environment but its working. Please help me fix the problem. Thanks in advance.
Environment variables can be defined permanently by editing the
.profile file in your home directory. Here's how:
.profile file with a command like
gedit ~/.profile. Append this to the end of the file:
source .profile to make it apply right away. Each time you restart your system, the
.profile file is loaded, restoring this setting.
Its not recommended to use
.profile file anymore to store user specific environment variables.
~/.pam_environment file instead.