2

I'm trying to execute multiple maven profiles using maven commandline

mvn clean process-resources -P<Profile1>,<Profile2>

But it only executes for Profile2, Profile1 is never executed. Help is required on executing multiple profiles through commandline.

Also note that when I list active profiles, it shows both profiles as active.

Rahul Yadav
  • 1,503
  • 8
  • 11
  • Can you paste here you pom.xml ? – Humberto Pinheiro May 04 '16 at 12:18
  • 2
    Think this is related : [Build multiple profiles in one go (Maven-2)](http://stackoverflow.com/questions/4932944/maven-build-multiple-profiles-in-one-go) and [build multiples artifacts with different classifiers at once](https://stackoverflow.com/questions/12320322/build-multiple-artifacts-with-different-classifiers-at-once) – Yassine Badache May 04 '16 at 12:23

1 Answers1

1
mvn clean install -P profile-1,profile-2

This should work fine. profiles doesn't have to be explicitly active.