2017-07-25 15 views
0

私たちはプロジェクトをSVNからGitに移行しようとしています。 Maven Release Pluginをmvn release:preparemvn release:performパッケージにしました。Maven Release PluginをSVNからGitに移行するには?

それに加えて、私たちはgitリポジトリを指すようにpom.xmlファイルのscmプロパティを変更しています。

はしかし、我々はmvn release:prepareを実行すると、次のエラーを取得:

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.5.1:prepare (default-cli) on project MyProject: Unable to check for local modifications 
[ERROR] Provider message: 
[ERROR] The svn command failed. 
[ERROR] Command output: 
[ERROR] 'svn' is not recognized as an internal or external command, 
[ERROR] operable program or batch file. 
[ERROR] -> [Help 1] 
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. 
[ERROR] Re-run Maven using the -X switch to enable full debug logging. 
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles: 
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException 
なぜそれがまだ cmd.exe /X /C "svn --non-interactive status"を実行しようとしている

? このリリースプロセスで完全に移行するには、他にどのような設定が必要ですか?

コンテキストのための私のpom.xmlの詳細は:

<scm> 
    <connection>scm:git:https://myGitProjectUrl.git</connection> 
    <developerConnection>scm:git:https://myGitProjectUrl.git</developerConnection> 
    <url>https://myGitProjectUrl</url> 
</scm> 
... 
<build> 
    <plugins> 
     <!-- Maven Release Plugin --> 
     <plugin> 
      <groupId>org.apache.maven.plugins</groupId> 
      <artifactId>maven-release-plugin</artifactId> 
      <version>2.5.1</version> 
      <configuration> 
       <goals>deploy</goals> 
      </configuration> 
     </plugin> 
+0

とgitのscmのURLでPOMファイル? –

+0

@RishikeshDarandale、良い質問です。はい、今私はトリプルチェックして確認しています。私はpom.xmlを含むローカルフォルダからコマンドを実行しています。フォルダは正しいプロジェクトであり、適切なgit repoと一致します。 – AlexScript

+0

すべてがうまく見えます。プラグインのバージョンを '2.5.3'に更新してみてください。 –

答えて

0

あなたはmaven-invoker依存してplugin下に試すことができます:あなたは正しいGitプロジェクトである場合は、確認してくださいすることができ

<build> 
    <plugins> 
     <plugin> 
      <groupId>org.apache.maven.plugins</groupId> 
      <artifactId>maven-release-plugin</artifactId> 
      <version>2.5.1</version> 
      <dependencies> 
      <dependency> 
       <groupId>org.apache.maven.shared</groupId> 
       <artifactId>maven-invoker</artifactId> 
       <version>2.2</version> 
      </dependency> 
      </dependencies> 
     </plugin> 
    </plugins> 

+0

依存関係は既に別の時間に定義する必要がない、maven-release-pluginの一部です... – khmarbaise

関連する問題