[
http://jira.codehaus.org/browse/MNG-4573?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=212250#action_212250
]
Grzegorz Slowikowski commented on MNG-4573:
-------------------------------------------
Expression in dependencyManagement section of "parent" module is evaluated in
context of "child" module, so ${project.parent.groupId} has "bug.mvn.sub" value
(which is project.parent.groupId of "child" module). Everything works as
expected.
As you can see, you can use expressions, but in your concrete example this
makes no sense.
> ${project.parent.groupId} not resolved properly in dependency management
> section
> --------------------------------------------------------------------------------
>
> Key: MNG-4573
> URL: http://jira.codehaus.org/browse/MNG-4573
> Project: Maven 2 & 3
> Issue Type: Bug
> Affects Versions: 2.2.1
> Environment: windows, jdk6u18
> Reporter: hatchetman82
> Assignee: Benjamin Bentmann
> Priority: Minor
> Attachments: grandparent.zip
>
>
> ${project.parent.groupId} in dependency management is resolved to
> ${project.groupId}
> this is demonstrated in the maven project i've attached, simply browse over
> to the "parent" module (child module of "grandparent") and issue the
> following command: "mvn help:effective-pom"
> this would reveal that
>
> <dependency>
> <groupId>${project.parent.groupId}</groupId>
> <artifactId>relative</artifactId>
> <version>1.0</version>
> </dependency>
> was translated into
> <dependency>
> <groupId>bug.mvn.sub</groupId>
> <artifactId>relative</artifactId>
> <version>1.0</version>
> </dependency>
> but module "grandparent" has a groupId of "bug.mvn"
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira