This is with maven 2.0.9 on Solaris 10 with Java 1.6.0_11

I have a project laid out thusly:

myproject/pom.xml
myproject/myproject-pom/pom.xml
myproject/myproject-api/pom.xml
myproject/myproject-common/pom.xml
myproject/myproject-console/pom.xml

The top-level pom is a minimal parent pom whose only module is
myproject/myproject-pom.

myproject/myproject-pom/pom.xml exists because Eclipse doesn't like nested
projects. So this pom has things that would typically need to be changed.

All of the other myproject/myproject-*/pom.xml are modules of
myproject/myproject-pom/pom.xml.

When I execute 'mvn release:prepare' things go well until it begins
invoking subversion. Here is the relevant bit of output from the process:
(sorry for the long lines)


[INFO] Executing: /bin/sh -c cd /export/home/ci/tmp/myproject && svn
--non-interactive commit --file /var/tmp/maven-scm-1461319678.commit
--targets /var/tmp/maven-scm-7441525038114668907-targets
[INFO] Working directory: /export/home/ci/tmp/myproject
[INFO] Executing: /bin/sh -c cd
/export/home/ci/tmp/myproject/myproject-pom && svn --non-interactive
commit --file /var/tmp/maven-scm-1292675052.commit --targets
/var/tmp/maven-scm-6618196211309587095-targets
[INFO] Working directory: /export/home/ci/tmp/myproject/myproject-pom
[INFO] Executing: /bin/sh -c cd
/export/home/ci/tmp/myproject/myproject-pom/../myproject-api && svn
--non-interactive commit --file /var/tmp/maven-scm-1794995489.commit
--targets /var/tmp/maven-scm-2050429634740604341-targets
[INFO] Working directory:
/export/home/ci/tmp/myproject/myproject-pom/../myproject-api
[INFO] Executing: /bin/sh -c cd
/export/home/ci/tmp/myproject/myproject-pom/../myproject-common && svn
--non-interactive commit --file /var/tmp/maven-scm-786958246.commit
--targets /var/tmp/maven-scm-6369822062244441127-targets
[INFO] Working directory:
/export/home/ci/tmp/myproject/myproject-pom/../myproject-common
[INFO] Executing: /bin/sh -c cd
/export/home/ci/tmp/myproject/myproject-pom/../myproject-console && svn
--non-interactive commit --file /var/tmp/maven-scm-637551884.commit
--targets /var/tmp/maven-scm-3757207476498104603-targets
[INFO] Working directory:
/export/home/ci/tmp/myproject/myproject-pom/../myproject-console
[INFO] Tagging release with the label myproject-1.0...
[INFO] Executing: /bin/sh -c cd /export/home/ci/tmp/myproject && svn
--non-interactive copy --file /var/tmp/maven-scm-1862162340.commit .
http://my-svn-server:8888/svn/myrepo/myprojects/tags/myproject-1.0
[INFO] Working directory: /export/home/ci/tmp/myproject
[INFO]
------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO]
------------------------------------------------------------------------
[INFO] Unable to tag SCM
Provider message:
The svn tag command failed.
Command output:
svn: Commit failed (details follow):
svn: File
'/svn/myrepo/myprojects/tags/myproject-1.0/myproject-common/pom.xml'
already exists


After investigating a while and trying to reproduce the process manually,
I discovered that the error message is somewhat misleading. If I do an
'svn update' prior to the 'svn copy' then the process completes
successfully.

I put a shell script named 'svn' in my path in front of /usr/local/bin and
had that script do an 'svn update' when it sees an 'svn copy' request.
Invoking 'mvn release:prepare' with that in place will succeed.

Has anybody else seen this kind of behavior? Is there a better solution
than my hack of a workaround:

$ cat ~/bin/svn
#!/bin/bash

echo "$@" > ~/svn.log

if [ "$1" = "--non-interactive" -a "$2" = "copy" -a "$3" = "--file" ]
then
  /usr/local/bin/svn update
fi

exec /usr/local/bin/svn "$@"



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org

Reply via email to