gpt4 book ai didi

macos - 如何在 MacO 上为 PhpStorm 更改 JRE

转载 作者:行者123 更新时间:2023-12-05 01:07:56 25 4
gpt4 key购买 nike

似乎随着最新的 MACOs 更新,Java 也更新了,这对 PhpStorm 的性能影响非常严重。

无论如何,我决定更新我的Java。

曾是

$ java -version
java version "1.6.0_51"
Java(TM) SE Runtime Environment (build 1.6.0_51-b11-457-11M4509)
Java HotSpot(TM) 64-Bit Server VM (build 20.51-b01-457, mixed mode)

从 Oracle 下载 Java SDK 并安装后:
$ java -version
java version "1.7.0_25"
Java(TM) SE Runtime Environment (build 1.7.0_25-b15)
Java HotSpot(TM) 64-Bit Server VM (build 23.25-b01, mixed mode)

但是在 PhpStorm 中它仍然显示旧的 JRE:
old jre

我也重新启动了我的计算机,但仍然显示旧的 JRE。

请帮忙,如何让 PHPStorm 使用新的 JRE?

最佳答案

引自 "Selecting the JDK version the IDE will run under" articleKnowledge Base
2013 年 3 月 27 日发布

Mac OS X

At the moment all our products require Apple JDK 1.6 to be installed in order to run on Mac. JDK 1.7 from Oracle is not officially supported yet and has known problems that stop us from using it by default. Oracle JDK 1.7.0_40 has added support for Retina and works much better than previous versions on Mac. You are welcome to give it a try in case you have any problems with Apple JDK.

To force running under JDK 1.7 edit /Applications/.app/Contents/Info.plist file, change JVMVersion from 1.6* to 1.7* :

<key>JVMVersion</key>
<string>1.7*</string>
  • See this answer for the known problems with JDK 1.7.
  • IDEA_JDK environment variable can be used to override the selected JDK, you may need to run the product from the Terminal so that it sees your environment variables (Mac OS limitation): open -a /Applications/.app/ .
  • Application About dialog will show the actual JDK version.

关于macos - 如何在 MacO 上为 PhpStorm 更改 JRE,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17743576/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com