After a lot of testing I found another solution. This solution is for people that work with SVN and only want to commit changes once the build succeeds, and need to use the latest revision for a build.
What this will do is retrieve the latest revision number from SVN and update the working copy. At the end of the build process it will check the revision number again, to ensure that no one has pushed any changes.
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>buildnumber-maven-plugin</artifactId>
<version>1.2</version>
<executions>
<execution>
<id>get-svn-local-revision-before</id>
<phase>validate</phase>
<goals>
<goal>create</goal>
</goals>
<configuration>
<doCheck>false</doCheck>
<doUpdate>true</doUpdate>
<buildNumberPropertyName>buildNumberLocal</buildNumberPropertyName>
<useLastCommittedRevision>true</useLastCommittedRevision>
</configuration>
</execution>
<execution>
<id>get-svn-remote-revision-before</id>
<phase>validate</phase>
<goals>
<goal>create</goal>
</goals>
<configuration>
<doCheck>false</doCheck>
<doUpdate>false</doUpdate>
<buildNumberPropertyName>buildNumberRemote</buildNumberPropertyName>
<useLastCommittedRevision>false</useLastCommittedRevision>
</configuration>
</execution>
<!-- Repeat after everything is done -->
<execution>
<id>get-svn-remote-revision-after</id>
<phase>verify</phase>
<goals>
<goal>create</goal>
</goals>
<configuration>
<doCheck>false</doCheck>
<doUpdate>false</doUpdate>
<buildNumberPropertyName>buildNumberRemote</buildNumberPropertyName>
<useLastCommittedRevision>false</useLastCommittedRevision>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>1.3.1</version>
<executions>
<execution>
<id>check-svn-revisions-before</id>
<phase>process-test-resources</phase>
<goals>
<goal>enforce</goal>
</goals>
<configuration>
<rules>
<evaluateBeanshell>
<condition>${buildNumberLocal} == ${buildNumberRemote}</condition>
<message>[ERROR] Local build (${buildNumberLocal}) doesn't match remote build (${buildNumberRemote})</message>
</evaluateBeanshell>
</rules>
<fail>true</fail>
</configuration>
</execution>
<!-- Repeat after everything is done -->
<execution>
<id>check-svn-revisions-after</id>
<phase>verify</phase>
<goals>
<goal>enforce</goal>
</goals>
<configuration>
<rules>
<evaluateBeanshell>
<condition>${buildNumberLocal} == ${buildNumberRemote}</condition>
<message>[ERROR] Local build (${buildNumberLocal}) doesn't match remote build (${buildNumberRemote})</message>
</evaluateBeanshell>
</rules>
<fail>true</fail>
</configuration>
</execution>
</executions>
</plugin>