Closed
Description
user @doubleuhy notes that:
gradle idea
Where:
Build file '/Users/zhouwuhong/elasticsearch/benchmarks/build.gradle' line: 31
What went wrong:
A problem occurred evaluating project ':benchmarks'.
Failed to apply plugin [id 'elasticsearch.build']
JAVA_HOME must be set to build Elasticsearch
but
echo $JAVA_HOME
/Library/Java/JavaVirtualMachines/jdk-10.jdk/Contents/Home
I have seen this in the past, including on SO. I think what happens is that importing the project from idea without running ./gradlew idea
first creates a daemon that is not restarted when running ./gradlew idea
from the command line with the env var set despite there being a different env.
Running ./gradlew --stop
makes the problem go away.