maven報錯

Unsupported IClasspathEntry kind=4

這個異常會致使項目沒法使用eclipse4.2的maven功能,我升級了maven的版本仍是不行java

 

 

英文解釋以下:spring

Please see https://bugs.eclipse.org/bugs/show_bug.cgi?id=374332#c14eclipse

The problem is caused by the fact that the STS (the Spring IDE/Eclipse) uses the m2e(clipse) plugin but that eclipse:eclipse has been probably been run on the project. When m2e encounters a "var" .classpath entry, it throws this error.maven

In order to fix this problem, you need to do 2 things:ide

  1. Make sure that the version of the m2e(clipse) plugin that you're running is at least 1.1.0. The update site is here: https://repository.sonatype.org/content/repositories/forge-sites/m2e/1.1.0/N/LATEST/this

  2. Disable the maven nature for the project (via the right-click menu), run mvn eclipse:clean (while your project is open in STS/eclipse), and then re-enable the maven nature.spa

中文解釋就是插件

問題是由於使用spring ide使用了m2eclipse 插件,可是這個插件的使用前提是不容許命令 mvn eclipse:eclipse在項目上執行過,若是執行過,就會拋出這個異常。code

現階段修復這個問題須要作兩件事orm

  一、保證m2e插件的版本高於 1.1.0,若是沒有到站點升級 :https://repository.sonatype.org/content/repositories/forge-sites/m2e/1.1.0/N/LATEST/

  二、去掉項目的maven特性,右鍵菜單就能去除,而後執行 mvn eclipse:clean,從新引入maven工程,不是java項目。

相關文章
相關標籤/搜索