问题描述:
从SVN下载maven项目后,发现缺少了Maven Dependencies,无论如何update project,clean,convert to maven....都无效。
解决:
检查项目的.classpath 文件,发现缺少了maven的classpathentry设置。
javaSE项目添加如下代码:
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
web项目添加:
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<attributes>
<attribute name="maven.pomderived" value="true"/>
<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
</attributes>
</classpathentry>
本文介绍了一种解决从SVN下载的Maven项目中MavenDependencies缺失的问题的方法。通过编辑项目的.classpath文件并添加特定的classpathentry设置,可以成功引入所需的依赖项。

被折叠的 条评论
为什么被折叠?



