mac 配置java环境
首先:
1: 下载新版的jdk:
http://www.oracle.com/technetwork/java/javase/downloads/index.html
2: 打开shell,输入 vi ~/.bash_profile
3:再.bash_profile中加入下几行:
export JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.8.0_60.jdk/Contents/Home
export PATH=$JAVA_HOME/bin:$PATH
export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
参考链接:
1: https://github.com/pubyun/macdev/blob/master/java.md
2: http://blog.csdn.net/abnerwang2014/article/details/24543543
df