I'm having problems when I run mvn release:prepare. I have the following message:
当我运行mvn release时,我遇到了问题:准备好了。我有以下消息:
[ERROR] Failed to execute goal org.apache.maven.plugins: maven-release-plugin: 2.5.1: prepare (default-cli) on project marketplace-po
c: Failed to invoke Maven build. Error configuring command-line. Reason: Maven executable not found at: C: \ dev \ apache-maven-3.3.1 \
bin \ mvn.bat -> [Help 1]
4 个解决方案
#1
84
As of version 3.3.X
, Maven renamed mvn.bat
to mvn.cmd
. This is fixed in the maven-release-plugin
version 2.5.2
: MRELEASE-902
从版本3.3.X开始,Maven将mvn.bat重命名为mvn.cmd。这在maven-release-plugin版本2.5.2:MRELEASE-902中得到修复
They suggest adding the following section in case the fixed plugin version is not picked up automatically:
他们建议添加以下部分,以防自动拾取固定插件版本:
<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>
</build>
#2
25
I just had same problem when running from eclipse, it resolved by making copy of mvn.cmd to mvn.bat
我从eclipse运行时遇到了同样的问题,它通过将mvn.cmd的副本复制到mvn.bat来解决
And it worked for me.
它对我有用。
#3
1
I had the same problem too at using Maven 3.3.1 in Windows 8.1. I searched on it and found that mvn.bat
moved to mvn.cmd
. Still, I don't know how to solve it at the version. So, I downloaded Maven 3.2.5 and there was the mvn.bat
file. And it worked for me.
在Windows 8.1中使用Maven 3.3.1时也遇到了同样的问题。我搜索它,发现mvn.bat移动到mvn.cmd。不过,我不知道如何在版本中解决它。所以,我下载了Maven 3.2.5并且有mvn.bat文件。它对我有用。
#4
-1
Fixed, i had same problem with maven 3.5.0 instalation, so just copy mvn.cmd and rename it to mvn.bat at C:\Program Files\apache-maven-3.5.0\bin.
修复了,我对maven 3.5.0 instalation有同样的问题,所以只需复制mvn.cmd并在C:\ Program Files \ apache-maven-3.5.0 \ bin将其重命名为mvn.bat。
#1
84
As of version 3.3.X
, Maven renamed mvn.bat
to mvn.cmd
. This is fixed in the maven-release-plugin
version 2.5.2
: MRELEASE-902
从版本3.3.X开始,Maven将mvn.bat重命名为mvn.cmd。这在maven-release-plugin版本2.5.2:MRELEASE-902中得到修复
They suggest adding the following section in case the fixed plugin version is not picked up automatically:
他们建议添加以下部分,以防自动拾取固定插件版本:
<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>
</build>
#2
25
I just had same problem when running from eclipse, it resolved by making copy of mvn.cmd to mvn.bat
我从eclipse运行时遇到了同样的问题,它通过将mvn.cmd的副本复制到mvn.bat来解决
And it worked for me.
它对我有用。
#3
1
I had the same problem too at using Maven 3.3.1 in Windows 8.1. I searched on it and found that mvn.bat
moved to mvn.cmd
. Still, I don't know how to solve it at the version. So, I downloaded Maven 3.2.5 and there was the mvn.bat
file. And it worked for me.
在Windows 8.1中使用Maven 3.3.1时也遇到了同样的问题。我搜索它,发现mvn.bat移动到mvn.cmd。不过,我不知道如何在版本中解决它。所以,我下载了Maven 3.2.5并且有mvn.bat文件。它对我有用。
#4
-1
Fixed, i had same problem with maven 3.5.0 instalation, so just copy mvn.cmd and rename it to mvn.bat at C:\Program Files\apache-maven-3.5.0\bin.
修复了,我对maven 3.5.0 instalation有同样的问题,所以只需复制mvn.cmd并在C:\ Program Files \ apache-maven-3.5.0 \ bin将其重命名为mvn.bat。