Skip to content

Commit

Permalink
Merge pull request #26 from jenkinsci/subversion-plugin-2.5
Browse files Browse the repository at this point in the history
Upgrade Subversion dependency version to 2.5.
Fix compatibility issues [JENKINS-26347] and [JENKINS-26357].
  • Loading branch information
hugueschabot committed Jan 10, 2015
2 parents 43842a2 + 41db8c3 commit a5c00fd
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 11 deletions.
6 changes: 3 additions & 3 deletions pom.xml
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>plugin</artifactId>
<version>1.509</version>
<version>1.568</version>
</parent>

<artifactId>svnmerge</artifactId>
Expand Down Expand Up @@ -49,12 +49,12 @@
<dependency>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>subversion</artifactId>
<version>2.4.4</version>
<version>2.5</version>
</dependency>
<dependency>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>promoted-builds</artifactId>
<version>2.10</version>
<version>2.15</version>
<optional>true</optional>
</dependency>
</dependencies>
Expand Down
Expand Up @@ -26,7 +26,9 @@
import org.kohsuke.stapler.interceptor.RequirePOST;
import org.tmatesoft.svn.core.SVNException;
import org.tmatesoft.svn.core.SVNNodeKind;
import org.tmatesoft.svn.core.SVNProperties;
import org.tmatesoft.svn.core.SVNURL;
import org.tmatesoft.svn.core.wc.SVNCopySource;
import org.tmatesoft.svn.core.wc.SVNInfo;
import org.tmatesoft.svn.core.wc.SVNRevision;

Expand Down Expand Up @@ -255,14 +257,17 @@ private boolean createSVNCopy(SvnClientManager svnMgr, ModuleLocation originalLo
try {
for (String urlToCopyTo : urlsToCopyTo) {
SVNURL dst = SVNURL.parseURIEncoded(urlToCopyTo);
svnMgr.getCopyClient().doCopy(originalLocation.getSVNURL(),
SVNRevision.HEAD,
dst,
false,
true,
commitMessage
);
}
svnMgr.getCopyClient().doCopy(
new SVNCopySource[] {
new SVNCopySource(SVNRevision.HEAD, SVNRevision.HEAD, originalLocation.getSVNURL()) },
dst,
false,
true,
true,
commitMessage,
new SVNProperties());
}

return true;
} catch (SVNException e) {
sendError(e);
Expand Down

0 comments on commit a5c00fd

Please sign in to comment.