轉賬自 https://blog.csdn.net/qq_36567480/article/details/90699356
當我們導入一個項目後,maven依賴的jar包在本地已經存在,但是缺沒有maven dependencies,如圖:
有時候導入的時候沒有上圖紅色圈出來的那部分,這時候我們可以在.classpath文件中加入
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>