在mac上Android Studio开发环境配置
-
打开终端:
java -version
得出结果:
java version "1.8.0_212" Java(TM) SE Runtime Environment (build 1.8.0_212-b10) Java HotSpot(TM) 64-Bit Server VM (build 25.212-b10, mixed mode)
-
打开终端:vim ~/.bash_profile
输入:a 进入编辑模式export JAVA_HOME="/Library/Java/JavaVirtualMachines/jdk1.8.0_212.jdk/Contents/Home" export PATH="$JAVA_HOME/bin:$PATH" export CLASSPATH=$JAVA_HOME/lib/tools.jar:$JAVA_HOME/lib/dt.jar export ANDROID_HOME=/Users/qiaosen/Library/Android/sdk
-
输入好,按ESC退出编辑模式 ,输入:wq
-
退出编辑模式时在命令行输入source ~/.bash_profile保存
-
配置Android sdk环境
export ANDROID_HOME=/Users/qiaosen/Library/Android/sdk export PATH=${PATH}:${ANDROID_HOME}/tools export Path=${PATH}:${ANDROID_HOME}/platform-tools
ok 基本完成了