Reputation: 599
I have tried a normal standard use of maven release plugin following the online help. But when I do a mvn release:prepare I get the following error (silverfish is the name of my project):
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.0:prepare (default-cli) on project silverfish: Unable to tag SCM
[ERROR] Provider message:
[ERROR] The svn tag command failed.
[ERROR] Command output:
[ERROR] svn: E200007: Source and destination URLs appear not to point to the same repository.
[ERROR] -> [Help 1]
Here's the scm part from my pom.xml:
<scm>
<connection>scm:svn:http://svnuser:[email protected]/scm/svn/silverfish</connection>
<url>http://viewurl</url>
</scm>
I think it has to do with the "user/passwd" part because the output of the maven process gives:
[INFO] Checking in modified POMs...
[INFO] Executing: /bin/sh -c cd /home/dittrich/NetBeansProjects/silverfish && svn --username svnuser --password '*****' --non-interactive commit --file /tmp/maven-scm-1445257989.commit --targets /tmp/maven-scm-7382722062367813549-targets
[INFO] Working directory: /home/dittrich/NetBeansProjects/silverfish
[INFO] Tagging release with the label silverfish-1.9...
[INFO] Executing: /bin/sh -c cd /home/dittrich/NetBeansProjects/silverfish && svn --username svnuser --password '*****' --non-interactive copy --file /tmp/maven-scm-723027784.commit --revision 106 http://some.address/scm/svn/silverfish 'http://svnuser:[email protected]/scm/svn/silverfish/tags/silverfish-1.9'
[INFO] Working directory: /home/dittrich/NetBeansProjects/silverfish
Note: the check-in part works without a problem, so the basic svn configuration seems to be ok.
It seems to me that the problem is that maven gives one url to the copy command without username password (using the --username and --password switches) and one with (using the user:passwd@sever syntax). And subversion then thinks these urls are not the same.
mvn copy http://some.address/scm/svn/silverfish 'http://svnuser:[email protected]/scm/svn/silverfish/tags/silverfish-1.9'
What I don't know if this is a subversion issue because subversion should understand that these urls are nevertheless the same. Or a Maven issue because Maven should use the same url syntax?
By the way I am using svn, Version 1.7.7 (r1393599) and my svn sever say's it is "Powered by SVN/1.7.5 SVNKit/1.7.5-2 (http://svnkit.com/) t20120724_0758" Apache Maven 3.0.4 Java version: 1.6.0_30, vendor: Sun Microsystems Inc.
Upvotes: 2
Views: 3716
Reputation: 46
Remove username and password from the SCM connection URL:
<scm>
<connection>scm:svn:http://some.address/scm/svn/silverfish</connection>
<url>http://viewurl</url>
</scm>
and add them to the release plugin:
<plugin>
<artifactId>maven-release-plugin</artifactId>
...
<configuration>
<username>${svn.username}</username>
<password>${svn.password}</password>
</configuration>
</plugin>
Upvotes: 2