IntelliJ not seeing resources folder

Marsellus Wallace picture Marsellus Wallace · Sep 7, 2012 · Viewed 25.1k times · Source

I created a new Project from scratch in IntelliJ by using a Maven Module. I didn't select any specific archetypes and I clicked on finish. The project gets created nicely and I have the java and resources folders under src/main as expected.

Unfortunately, my application does not find any property files in the resources folder because it looks in the project base folder instead.

I double checked that the resources folder is marked as 'source folder' in the Project Structure and I also tried to add the following to the pom.xml with no success:

<resources>
  <resource>
    <directory>src/main/resources</directory>
  </resource>
</resources>

I'm using Maven 2.2.1 and IntelliJ 11.1, Any thoughts??

Answer

Ichtion picture Ichtion · Aug 9, 2013

There is a bug in Intellij 12 please go to Settings->Compiler and un-check "Use external build" check box - the idea behind it was that it was suppose to run faster with a compiler run in a separate process but in fact there is a bug and when using maven it does not copy resources.