Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

versions:set is not propagated to submodules if they don't inherit aggregator pom #37

Closed
jakub-bochenski opened this issue Nov 2, 2015 · 9 comments
Milestone

Comments

@jakub-bochenski
Copy link

If we have a project A with modules B & C where :

  • B inherit from A
  • C DOESN'T inherit from A

When we execute the following command line :
mvn org.codehaus.mojo:versions-maven-plugin:2.2:set -DnewVersion=0.1

Only A & B are updated.
The fact that C doesn't inherit from A (whereas C is a module of A) doesn't make it updated.

Previously known as MVERSIONS-131

@jakub-bochenski
Copy link
Author

I see this can be achieved by using -DartifactId='*' but this option is not documented anywhere

@khmarbaise khmarbaise added this to the 2.4.1 milestone Jun 15, 2017
@dantran
Copy link

dantran commented Jun 16, 2017

this is not working for me with -DartifactId='*'. Basically nothing change to all my poms
i have a module in my module list which does not inherit from main tree. Something like this

main
    module-1
        pom.xml
    module-2
        pom.xml
    folder-x/module-3
                     pom.xml

module 3 does not inherit from the top parent

@dantran
Copy link

dantran commented Jun 17, 2017

this is platform specific, on windows, -DartifactId=* -DgroupId=* no single quotes

@dantran
Copy link

dantran commented Jun 17, 2017

i think this plugin should remove the single quote to deal with windows

@khmarbaise
Copy link
Member

Hi Dan, have you set -DoldVersion='*' ? Furthermore does the module which does not inherit form the main tree has the same group ? If not you have to give -DgroupId='*' ..?

@dantran
Copy link

dantran commented Jun 17, 2017

yes for my case, i need to use

-DgroupId='*' -DartifactId='*'   on unix/cygwin

-DgroupId=* -DartifactId=*  on windows

there is no need to use -DoldVersion since i have same version for entire reactor

@khmarbaise
Copy link
Member

Ok. That means it works for you now correctly. But I think there should be note for using the quotes on Windows vs. Linux/Unix...( added to the docs for groupId, artifactId and oldVersion for the set goal).

@dantran
Copy link

dantran commented Jun 17, 2017

may be better to trim the surround quotes inside the MOJO?

@khmarbaise
Copy link
Member

khmarbaise commented Jun 17, 2017

Ok I will open another issue for that purpose. #170. I have rechecked the quoting parts is already handled by Maven itself during the command line parsing. If you take a look into debug output you will see that the quotes are already removed...So no need for that...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants