Luciano
Luciano

Reputation: 8582

Maven profiles being ignored in Intellij IDEA 12

My project has some .JARs that are defined in profiles. For instance, load the PostgreSQL JAR if the PostgreSQL profile is active, or load the MySQL JAR if the MySQL profile is active.

I have this project imported to IDEA, and set the PostgreSQL profile active in the Maven Panel, yet the jar is not added when the artifact is built, so it's not deployed to Tomcat, and then the WebApp doesn't start.

What am I missing?

Upvotes: 4

Views: 3579

Answers (2)

Luciano
Luciano

Reputation: 8582

Looks like it's an acknowledged bug in Intellij IDEA.

Upvotes: 2

zpontikas
zpontikas

Reputation: 5662

I had a similar problem. Some projects had the <activeByDefault>true</activeByDefault> option in some of the profiles and they would not build (cos I have more that one maven modules in my project).

I removed that option and activeted each profile for each project alone. I worked but the behaviour is not the same with that of IntelliJ 11 or 10. Hope this helps.

Upvotes: 2

Related Questions