2013-06-03 228 views
1
/bin/sh: svn: command not found 
Caused by: org.apache.maven.plugin.MojoFailureException: Unable to check for local modifications 
Provider message: 
The svn command failed. 

即使已經安裝了「Subversion插件」,詹金斯也找不到Subversion。詹金斯Subversion

回答

10

此錯誤的原因是您必須在pom.xml中明確定義maven-release-plugin應該使用svnkit。

方法如下:

<build> 
    <plugins> 
     <plugin> 
      <groupId>org.apache.maven.plugins</groupId> 
      <artifactId>maven-release-plugin</artifactId> 
      <version>2.4.1</version> 
      <configuration> 
       <goals>clean install</goals> 
       <providerImplementations> 
        <svn>javasvn</svn> 
       </providerImplementations> 
      </configuration> 
      <dependencies> 
       <dependency> 
        <groupId>com.google.code.maven-scm-provider-svnjava</groupId> 
        <artifactId>maven-scm-provider-svnjava</artifactId> 
        <version>2.0.5</version> 
        <scope>compile</scope> 
       </dependency> 
      </dependencies> 
     </plugin> 
    </plugins> 
</build> 
0

你需要在你的機器上安裝顛覆。如果您的操作系統是Centos,您可以運行

yum install subversion