标签:maven
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-archetype-plugin:2.2:create-from-project (default-cli) on
project shiro_learn2: Error configuring command-line. Reason: Maven executable not found at: D:\HwProgramFiles\maven\apa
che-maven-3.3.3\bin\mvn.bat -> [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
配置:windows–>preferences–>Maven–>UserSetting
参考文档:
出现该问题原因:在Maven工程中的pom.xml中引入以下内容:
<dependency>
<groupId>org.forgerock.openam</groupId>
<artifactId>openam-oauth2</artifactId>
<version>${openam.version}</version>
</dependency>
${openam.version}
,将其改为12.0.0就可以了,难道Maven不支持${openam.version}
这种写法?可我是在github中直接clone过来的呀(看来Maven还要好好学习呀)错误提示
解决方法
第一步:参照下面的参考文档,对自己工程中的相关文档进行修改
第二步:★右键项目 > Maven > Update Project Configuration。OK完美解决
<dependency>
<groupId>org.wltea</groupId>
<artifactId>IKAnalyzer</artifactId>
<version>3.2.8</version> <systemPath>C:\Users\yangping\Desktop\a\IKAnalyzer3.2.8.jar</systemPath>
</dependency>
第一步:将要安装的jar包拷贝到仓库相应目录下并在该目录下创建hw-openam-restlet-extension-0.0.1.pom
<?xml version="1.0"encoding="UTF-8"?>
<projectxsi:schemaLocation="http://maven.apache.org/POM/4.0.0http://maven.apache.org/xsd/maven-4.0.0.xsd"xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>
<groupId>openam</groupId>
<artifactId>hw-openam-restlet-extension</artifactId>
<version>0.0.1</version>
<description>Hw Local openam Repository</description>
</project>
第二步:打开cmd ,进入到F:\bx_maven2.m2\repository\com\myxmlbean\customerXmlBean\2.6.0文件夹,运行下面命令如下命令:
mvn install:install-file -Dfile=chw-openam-restlet-extension-0.0.1.jar -DgroupId=openam -DartifactId=hw-openam-restlet-extension -Dversion=0.0.1 -Dpackaging=jar
参考文档:http://m.blog.csdn.net/blog/lock0531/25891159
标签:maven
原文地址:http://blog.csdn.net/heweirun_2014/article/details/46558329