mac 安裝jdk環境

jdk 1.8 安裝

cd ~

打開編輯.bash_profile

open .bash_profile

如果出現The file /xxxx/.bash_profile does not exist的情況,需要創建.bash_profile文件

touch .bash_profile

然后再open .bash_profile,在彈出的操作框中輸入

export JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.8.0_25f1.jdk/Contents/Home

并保存
這時在終端輸入

java -version

就能看到安裝成功了

?著作權歸作者所有,轉載或內容合作請聯系作者
平臺聲明:文章內容(如有圖片或視頻亦包括在內)由作者上傳并發布,文章內容僅代表作者本人觀點,簡書系信息發布平臺,僅提供信息存儲服務。