Mac OS上的IntelliJ IDEA JDK配置 [英] IntelliJ IDEA JDK configuration on Mac OS

查看:1912
本文介绍了Mac OS上的IntelliJ IDEA JDK配置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用IntelliJ IDEA 10.每次创建新项目时,都要求我为此项目选择JDK。任何人都知道如何配置它并使其易于使用?

I am using IntelliJ IDEA 10. Every time when I create a new project, it is asking me to choose JDK for this project. Anyone know how I can configure it and make it easy to use?

推荐答案

如果您使用的是Mac OS X或Ubuntu,问题是由JDK的符号链接引起的。档案|无效缓存应该有所帮助。如果没有,请指定直接JDK主文件夹的JDK路径,而不是符号链接。

If you are on Mac OS X or Ubuntu, the problem is caused by the symlinks to the JDK. File | Invalidate Caches should help. If it doesn't, specify the JDK path to the direct JDK Home folder, not a symlink.

无效缓存菜单项在IntelliJ IDEA 文件菜单。

Invalidate Caches menu item is available under IntelliJ IDEA File menu.

最近Apple Java更新后的直接JDK路径:

Direct JDK path after the recent Apple Java update is:

/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home

在IDEA中,您可以在文件|中配置新的JSDK项目结构,选择左侧的 SDK ,然后按 [+] 按钮,然后指定上面的JDK主路径,您应该得到以下内容:

In IDEA you can configure the new JSDK in File | Project Structure, select SDKs on the left, then press [+] button, then specify the above JDK home path, you should get something like this:

这篇关于Mac OS上的IntelliJ IDEA JDK配置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆