每当我尝试使用Intellij中的gradle做任何事情时,我都会收到如下错误:
Executing command: "tasks"
Failed to connect to gradle process for command 'tasks'
ERROR: JAVA_HOME is set to an invalid directory: C:\Program Files (x86)\JetBrains\IntelliJ IDEA 10.0\jre
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation.
Run Code Online (Sandbox Code Playgroud)
但是在我的环境中,我已经JAVA_HOME在不同的目录中设置了正确的JDK.此外,当我查看IntelliJ项目时,它还会在正确的JDK位置显示JDK.我找不到任何试图将JDK指向Intellij JRE位置的东西.
有什么想法吗?