新的maven原型生成

时间:2014-06-28 23:31:26

标签: java windows maven unix

我正在学习使用maven atm,出于某种原因我遇到了这个错误。我目前正在关注Java Brain的Maven教程,当我输入命令mvn archtype:generate时。它开始下载所有插件,但它会跳过我输入的部分选择一个数字或应用过滤器,然后直接搜索项目。

Matt@El_Laptop ~/my_app
$ mvn archtype:generate
[INFO] Scanning for projects...
Downloading: http://repo.maven.apache.org/maven2/org/codehaus/mojo/maven-metadata.xml
Downloading: http://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-
metadata.xml
Downloaded: http://repo.maven.apache.org/maven2/org/codehaus/mojo/maven-metadata.xml   
(22 KB at 34.9 KB/sec)
Downloaded: http://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-
metadata.xml (13 KB at 19.3 KB/sec)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4.377 s
[INFO] Finished at: 2014-06-28T16:02:14-08:00
[INFO] Final Memory: 8M/94M
[INFO] ------------------------------------------------------------------------
[ERROR] No plugin found for prefix 'archtype' in the current project and in the plugin 
groups [org.apache.maven.plugins, org.codehaus.mojo] available from the repositories    
[local (C:\Users\Matt\.m2\repository), central (http://repo.maven.apache.org/maven2)] -  
> [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/NoPluginFoundForPrefixException

1 个答案:

答案 0 :(得分:0)

该插件名为原型(不是archtype)。