Showing posts with label relase. Show all posts
Showing posts with label relase. Show all posts

Friday, February 21, 2014

release:prepare - You don't have a SNAPSHOT project in the reactor projects list.

Sometimes during executing mvn release:prepare following error ocures:
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.995s
[INFO] Finished at: Fri Feb 21 11:19:01 CET 2014
[INFO] Final Memory: 11M/241M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.3.2:prepare (default-cli) on project cubiculus-ldraw: You don't have a SNAPSHOT project in the reactor projects list. -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.3.2:prepare (default-cli) on project [project-name]: You don't have a SNAPSHOT project in the reactor projects list.

In other words it say that your pom.xml file is not in SNAPSHOT version (for example 1.4-SNAPSHOT) but contains release version (for example 1.4.3). One to the reasons of this problem could be that previous attempt to release project failed and during it's work changed project version to release version. Check your repository that there is correct SNAPSHOT versions and synchronise repo. In case of SVN "svn revert -R ."

Maven release - svn problem

I have met following problem during releasing of maven project.
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 14.759s
[INFO] Finished at: Fri Feb 21 09:26:53 CET 2014
[INFO] Final Memory: 12M/191M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.3.2:prepare (default-cli) on project [project_name]: Unable to check for local modifications
[ERROR] Provider message:
[ERROR] The svn command failed.
[ERROR] Command output:
[ERROR] svn: The path '.' appears to be part of a Subversion 1.7 or greater
[ERROR] working copy.  Please upgrade your Subversion client to use this
[ERROR] working copy.
[ERROR] -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.3.2:prepare (default-cli) on project [project_name]: Unable to check for local modifications
Provider message:
The svn command failed.
Command output:
svn: The path '.' appears to be part of a Subversion 1.7 or greater
working copy.  Please upgrade your Subversion client to use this
working copy.

 at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:212)
 at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
 at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
 at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
 at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
 at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
 at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
 at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:318)
 at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:153)
 at org.apache.maven.cli.MavenCli.execute(MavenCli.java:555)
 at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:214)
 at org.apache.maven.cli.MavenCli.main(MavenCli.java:158)
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
 at java.lang.reflect.Method.invoke(Method.java:597)
 at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
 at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
 at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:414)
 at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:357)
Caused by: org.apache.maven.plugin.MojoFailureException: Unable to check for local modifications

Previous problem is caused by SVN client version incompatibility. Project was probably checkout from repository in Eclipse and maven release prepare command was run from command line. At command line is client version 1.6. This is problem. There are few ways how to solve it:

  • Easiest solution is to perform subversion related operation with console. Some basic examples with description could be found here.
  • Command line subversion client could be updated to version 1.7
  • In eclipse is plugin which is responsible for subversion handling. It's in eclipse configuration in "Team" and there in "SVN". There is list of available SVN client libraries. There could be selected at least "SVNKit" and "JavaHL JNI". You can try to install correct version of JavaHL of find correct SVNKit version. This both approaches are well described at google.