Maven error - invalid source release: 8
I have a new, empty module which I'm trying to configure to use Maven (there are no dependencies yet).
I have Maven configured for targeting Java 8 and while this does correctly set the module language settings to 1.8, the Maven compilation still fails.
Note that the logging seems to indicate that it's using Java 7 for running Maven.
I have already set the Maven Runner to use my 1.8 SDK. Am I missing something else, or is this a bug?
Compilation works fine if I switch the pom file to target 1.7.
Thanks!
请先登录再写评论。
I'm using the latest version of IDEA 13, by the way.
You need to adjust your module SDK.
Go to "Project Settings / Modules / <YOUR MODULE> / Dependecies" and choose Module SDK (see attached screenshot)
Attachment(s):
maven_sdk.png
That did it, thanks.