mvn.bat没有正确执行

时间:2014-10-06 09:02:24

标签: maven

在我的机器中设置maven&mvn.bat'没有正确执行。给出错误"没有为此构建指定目标......"。

JAVA_HOME设置得很好。 虽然“mvn --version'。

没有错误。”

1 个答案:

答案 0 :(得分:1)

实际上,这个错误是不言自明的:

No goals have been specified for this build.     
You must specify a valid lifecycle phase or a goal in the format 
<plugin-prefix>:<goal> or <plugin-group-id>:<plugin-artifact-id>[:<plugin-version>]:<goal>.
Available lifecycle phases are: validate, initialize, generate-sources, process-sources,
generate-resources, process-resources, compile, process-classes, generate-test-sources,
process-test-sources, generate-test-resources, process-test-resources, test-compile,
process-test-classes, test, prepare-package, package, pre-integration-test, 
integration-test, post-integration-test, verify, install, deploy, pre-site, site,
post-site, site-deploy, pre-clean, clean, post-clean.

您尚未指定任何目标。你必须。您最有可能想要mvn installmvn clean install。我建议阅读Maven用法和示例。