Hi,
I am trying to use versions:use-release feature in version maven plugin to
manipulate my pom file. But it turns out that it can find release version
if it is available in .m2. If the release version is available in remote
repository but not in .m2, it can not find the release version of an
module. Is this expected behavior?
Here is my story in details:
I need to replace my module's parent and dependent modules' snapshot
version with release version for the process of release.
First, I run "mvn versions:set -DremoveSnapshot=true versions:commit" to
remove my module's snapshot version. It works well.
Next, I run "mvn versions:use-releases -DprocessParent=true
versions:commit". It does not do anything. From the output of mvn,
```
[INFO] artifact com.xxxxx:parent: checking for updates from maven-group
[INFO] artifact com.xxxxx:parent: checking for updates from central
```
It seems that it checks my repo, "maven-group", but it could not find it. I
do have parent release verion in "maven-group", 0.0.3. the snapshot version
in my pom is 0.0.3-SNAPSHOT.
However, if I build the release version of my parent in my local machine
(the 0.0.3 of parent will be in .m2), this command can update parent module
from 0.0.3-SNAPSHOT to 0.0.3. Same thing for dependent module. So it looks
to me that versions:use-release only only find the release version info in
.m2.
Here is my repo in pom. I use nexus repo. maven-group is the entry for
release and snapshot repo.
```
<repository>
<id>maven-group</id>
<url>http://192.168.xxx.xxx:8081/repository/maven-group/</url>
</repository>
```
Do anyone have some ideas? I have tried to add
```
<id>maven-group</id>
<url>http://192.168.xxx.xx:8081/repository/maven-group/</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
<releases>
<enabled>true</enabled>"
</releases>"
```
for maven-group or directly use maven-releases or maven-snapshots repo in
pom file. But none of them works.
Any ideas or suggestions? I also tried to use mvn -X, it does not give more
detailed information. If it finds the release version, it just print
"update ....". Otherwise, no debug information available on what it could
not find release version on remote repository.
Thank you!
--
You received this message because you are subscribed to the Google Groups
"mojohaus-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/mojohaus-dev/986db658-fc3f-4727-b9a5-7f7462ee805e%40googlegroups.com.