maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Richard Bone (JIRA)" <>
Subject [jira] (MNG-5271) Cannot resolve active profile name at build time
Date Mon, 09 Apr 2012 22:20:02 GMT
Richard Bone created MNG-5271:

             Summary: Cannot resolve active profile name at build time
                 Key: MNG-5271
             Project: Maven 2 & 3
          Issue Type: Bug
          Components: Profiles
    Affects Versions: 3.0
         Environment: Mac OS 10.6
            Reporter: Richard Bone

I have a maven profile defined in my pom.  It's not active by default, so I run -P <profilename>.
When the profile is running, I want to construct a path that includes the name of the profile.
 I've looked online  and it appears that

would have the answer.  Alas, it doesn't work for me at build time.  If I do a mvn help:evaluate
-P <profilename> and use ${projects.activeProfiles[0].id}, I get the value I would expect.
 When I run in the build, though, it doesn't resolve and just uses the literal value in the

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


View raw message