错误信息:
[
ERROR
]
BUILD ERROR
[ INFO ] ------------------------------------------------------------------------
[ INFO ] The plugin 'org.apache.maven.plugins:maven-clean-plugin' does not exist or no valid version could be found
[ INFO ] ------------------------------------------------------------------------
[ INFO ] For more information , run Maven with the -e switch
[ INFO ] ------------------------------------------------------------------------
[ INFO ] The plugin 'org.apache.maven.plugins:maven-clean-plugin' does not exist or no valid version could be found
[ INFO ] ------------------------------------------------------------------------
[ INFO ] For more information , run Maven with the -e switch
原因:
maven 的clean 插件的配置文件里面没有版本号<versioning />
使用 d:/maven2/bin/mvn org.apache.maven.plugins:maven-clean-plugin:2.1.1:clean 命令可以执行
或则修改下面文件:
D:/maven2/m2repository/org/apache/maven/plugins/maven-clean-plugin/maven-metadata.xml
<?
xml version="1.0"
?>
<
metadata
>
< groupId > org.apache.maven.plugins </ groupId >
< artifactId > maven-clean-plugin </ artifactId >
< versioning >
< latest > 2.1 </ latest >
< release > 2.1 </ release >
< versions >
< version > 2.0-beta-1 </ version >
< version > 2.0-rc1 </ version >
< version > 2.0 </ version >
< version > 2.1 </ version >
</ versions >
< lastUpdated > 20060220044115 </ lastUpdated >
</ versioning >
</ metadata >
< groupId > org.apache.maven.plugins </ groupId >
< artifactId > maven-clean-plugin </ artifactId >
< versioning >
< latest > 2.1 </ latest >
< release > 2.1 </ release >
< versions >
< version > 2.0-beta-1 </ version >
< version > 2.0-rc1 </ version >
< version > 2.0 </ version >
< version > 2.1 </ version >
</ versions >
< lastUpdated > 20060220044115 </ lastUpdated >
</ versioning >
</ metadata >