A typical install of OS X won ' t create a. Bash_profile for you. When you want to run functions from your command line, this is a must-have.
- Start up Terminal
- Type "CD ~/" to go to your home folder
- Type "touch. Bash_profile" To create your new file.
- Edit. Bash_profile with your favorite editor (or you can just type ' open-e. Bash_profile ' to ' open it in TextEdit.
- Contents:export android_home="/usr/local/adt/sdk"
- Type ". Bash_profile "to reload. Bash_profile and update any functions you add.
Ps:
In Mac systems, the JDK has a different installation path than Windows, and the default directory is:/system/libray/frameworks/javavm.framwork/.
Export Java_home = "/system/libray/frameworks/javavm.framwork/versions/currentjdk/home"
You can also refer to:
Http://www.cnblogs.com/mokey/p/3542389.html
. Bash_profile for Mac ' envionment variables