I am having trouble compiling a Maven project in IntelliJ.
mvn clean install
from commandline = SUCCESSTherefore I don't believe there is anything wrong with the project itself. But
I have
What else could I try to make IntelliJ intelligent enough to compile the project?
This can happen if command line uses a different version of mvn than IntelliJ. Make sure that Intellij is using the same maven executable that command line is using. First type: "which mvn" to find out the mvn executable that command line is using. Then make IntelliJ use the same version by going to: Intellij => Preferences => Build, Execution and Deployment => Build Tools => Maven => Maven Home Directory. Mvn Settings in IntelliJ 2017.1
I faced similar problem. Solution is, set the IntelliJ maven home directory to the installed maven location. Goto File->Settings And then set the maven home directory as shown in the image:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With