maven入门
2018-06-18 01:31:31来源:未知 阅读 ()
1、关于Idea中右边的maven projects窗口找不到了如何调出来
关于Idea中右边的maven projects窗口找不到了如何调出来?
具体的idea版本我不太清楚,我用的是2016版,其他版本应该也是一样的。
首先idea自带了maven控件,不像Eclipse还需要下载控件,如果你以前有maven在右边,出于某种原因,消失找不到 了,你可以试试我写的方法。
方法1.你点击一下你idea界面最左下角的那个小框,maven应该从里面找到
方法2.点击菜单栏View->Tool
Windows->Maven projects
方法3.点击菜单栏Help->Find Action(Ctrl+Shift+A),输入Maven projects
2、错误
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.20.1:test (default-test) on project course: Execution default-test of goal org.apache.maven.plugins:maven-surefire-plugin:2.20.1:test failed.: NullPointerException -> [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/PluginExecutionException
点击错误链接得到
This error is reported in case the execution of a plugin failed due to some unforeseen event. For example, uncatched runtime exceptions caused by the plugin will raise this error. You should report this problem to the maintainer of the plugin.
如果插件的执行由于某些不可预见的事件而失败,则会报告此错误。 例如,由插件引起的未捕获的运行时异常将引发此错误。 你应该将这个问题报告给插件的维护者。
总结
1. 理论上来讲不做mvn clean 得到的jar包应该是最新的,除非其他方式修改jar包中的内容而不修改源代码。
2. 平时可以用mvn install,而不进行chean节省时间(如果你觉得节省时间多的话),但最保险还是用 mvn clean
install 生成最新的jar包或其他包
3. 不想用mvn clean又想保证jar包最新,建议添加 -Djar.forceCreation 参数
jar-plugin源代码地址:http://svn.apache.org/repos/asf/maven/plugins/tags/maven-jar-plugin-2.4
解决方法2:使用插件,在相应pom.xml文件里面,修改
<configuration> <testFailureIgnore>true</testFailureIgnore> </configuration>
失败
增加@ignore失败
Execution default-test of goal org.apache.maven.plugins:maven-surefire-plugin:2.20.1:test failed.: NullPointerException -> [Help 1]
解决办法:
在pom.xml文件里面修改:
<build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-surefire-plugin</artifactId> <version>2.6</version> <configuration> <skipTests>true</skipTests> </configuration> </plugin> </plugins> </build>
标签:
版权申明:本站文章部分自网络,如有侵权,请联系:west999com@outlook.com
特别注意:本站所有转载文章言论不代表本站观点,本站所提供的摄影照片,插画,设计作品,如需使用,请与原作者联系,版权归原作者所有
- logstash系列-入门整理 2020-06-10
- eclipse下创建Maven项目(包含webapp目录结构) 2020-06-09
- Maven安装与配置 2020-06-09
- Java 入门教程 2020-06-09
- RocketMQ4.4 入门进阶+实战 2020-06-08
IDC资讯: 主机资讯 注册资讯 托管资讯 vps资讯 网站建设
网站运营: 建站经验 策划盈利 搜索优化 网站推广 免费资源
网络编程: Asp.Net编程 Asp编程 Php编程 Xml编程 Access Mssql Mysql 其它
服务器技术: Web服务器 Ftp服务器 Mail服务器 Dns服务器 安全防护
软件技巧: 其它软件 Word Excel Powerpoint Ghost Vista QQ空间 QQ FlashGet 迅雷
网页制作: FrontPages Dreamweaver Javascript css photoshop fireworks Flash
