[ 
https://issues.apache.org/jira/browse/MNG-6378?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16565994#comment-16565994
 ] 

Gordon Pettey edited comment on MNG-6378 at 8/1/18 9:11 PM:
------------------------------------------------------------

I have no current use case for the first, but after using Maven for a long 
time, you forget what issues you ran into and worked around years ago.

These dependencies are specific to the profile. Putting them in the main 
dependencyManagement pom doesn't quite fit. Regardless, they will be the same 
version as dependencies in the main, and avoiding duplicating the version and 
it getting out of sync is the point of this.
Duplicating a module just to run one plugin execution seems odd. I'm 
specifically using Checker Framework for this point and the above. See their 
[sample|https://checkerframework.org/manual/#maven] configuration. I keep this 
in a profile along with deploy and jar plugins skipped so checker doesn't 
accidentally become a dependency of anything deployed.

No, because the URL string in pluginManagement is based on the dependency 
version, and without the property from the import-scoped pom, that URL can't be 
built. The point is I don't want to have to duplicate that version number in 
both POMs, yet I need it available in both.

On the last point, building a CLI application that has a "--version" command, I 
may want to mention versions of used libraries. I use a versions.properties 
file like {{libraryname=${versions.libraryname}}} that are the same properties 
my pom uses.


was (Author: gpettey):
I have no _current_ use case for the first, but after using Maven for a long 
time, you forget what issues you ran into and worked around years ago.

These dependencies are specific to the profile. Putting them in the main 
dependencyManagement pom doesn't quite fit. Regardless, they will be the same 
version as dependencies in the main, and avoiding duplicating the version and 
it getting out of sync is the point of this.
Duplicating a module just to run one plugin execution seems odd. I'm 
specifically using Checker Framework for this point and the above. See their 
[sample|https://checkerframework.org/manual/#maven] configuration. I keep this 
in a profile along with deploy and jar plugins skipped so checker doesn't 
accidentally become a dependency of anything deployed.

No, because the URL string in pluginManagement is based on the dependency 
version, and without the property from the import-scoped pom, that URL can't be 
built. The point is I don't want to have to duplicate that version number in 
both POMs, yet I need it available in both.

On the last point, building a CLI application that has a "--version" command, I 
may want to mention versions of used libraries. I use a versions.properties 
file like {{libraryname=${versions.libraryname}}} that are the same properties 
my pom uses.

> Properties from POM in import scope should be resolvable in the project
> -----------------------------------------------------------------------
>
>                 Key: MNG-6378
>                 URL: https://issues.apache.org/jira/browse/MNG-6378
>             Project: Maven
>          Issue Type: Improvement
>            Reporter: Jakub Kubrynski
>            Priority: Major
>             Fix For: waiting-for-feedback
>
>
> Properties defined in the POM that is in the import scope in the 
> dependencyManagement section should be able to resolve in the project. It's 
> especially important in the framework (like Spring) using BOM patterns



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to