在Windows 7 cmd控制台中使用maven 3.0.3:
mvn archetype:generate -DgroupId =“com.maven”-DartifactId =“web”-DarchetypeArtifactId = maven-archetype-quickstart -DinteractiveMode = false
maven-archetype-quickstart有效,但maven-achetype-webapp没有:
mvn archetype:generate -DgroupId =“com.maven”-DartifactId =“web”-DarchetypeArtifactId = maven-achetype-webapp -DinteractiveMode = false
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Maven Stub Project (No POM) 1
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] >>> maven-archetype-plugin:2.2:generate (default-cli) @ standalone-pom >>>
[INFO]
[INFO] <<< maven-archetype-plugin:2.2:generate (default-cli) @ standalone-pom <<<
[INFO]
[INFO] --- maven-archetype-plugin:2.2:generate (default-cli) @ standalone-pom ---
[INFO] Generating project in Batch mode
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.212s
[INFO] Finished at: Tue Feb 12 17:02:01 EST 2013
[INFO] Final Memory: 14M/154M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-archetype-plugin:2.2:generate (default-cli) on project standalone-pom: The desired archetype does
not exist (org.apache.maven.archetypes:maven-achetype-webapp:1.0) -> [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
答案 0 :(得分:2)
我想你可能有一个拼写错误:不应该是maven-aRchetype-webapp
吗? (R缺失)