tags:

views:

12

answers:

1

This is my pom.xml (portion of it):

<profiles>
  <profile>
    <id>production</id>
    ...
  </profile>
</profile>

This is my profiles.xml:

<profilesXml>
  <profiles>
    <profile>
      <id>production</id>
      ...
    </profile>
  </profiles>
</profilesXml>

Maven says:

[WARNING] Overriding profile: 'production' (source: pom) with
new instance from source: profiles.xml

What am I doing wrong?

+1  A: 

Well, you can. But the warning message is pretty clear: the profile from the external file will override the one from the pom.

PS: As a side note, I really wonder why you're "playing" with the profiles.xml which is deprecated and removed from Maven 3. That's just a dead feature.

Pascal Thivent
Hm.. Didn't know that.. Ok, thanks for the notice.
Vincenzo
@FaZend.com: You're welcome.
Pascal Thivent
@FaZend.com: By the way, the common way of recognizing a good answer is upvoting it ;) (see also http://meta.stackoverflow.com/questions/686/accepting-answer-without-upvoting).
Pascal Thivent
Of course, done! :)
Vincenzo