java - How to generate eclipse project from maven with "Maven Dependencies" instead of "Referenced Libraries" "M2_REPO/.." -


how can generate eclipse project maven :

mvn eclipse:eclipse  

but need .classpath file :

<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> 

instead of having dependencies pom :

<classpathentry kind="var" path="m2_repo/javax/servlet/javax.servlet-api/3.1.0/javax.servlet-api-3.1.0.jar" sourcepath="m2_repo/javax/servlet/javax.servlet-api/3.1.0/javax.servlet-api-3.1.0-sources.jar"> <attributes>   <attribute value="jar:file:/home/tr/.m2/repository/javax/servlet/javax.servlet-api/3.1.0/javax.servlet-api-3.1.0-javadoc.jar!/" name="javadoc_location"/> </attributes> 

....

the problem conflicting m2e , mvn eclipse classpath entries. if run eclipse:eclipse well, see referenced libraries added classpath.

the way import run mvn eclipse:clean on project command line first , import maven project using eclipse m2e maven plugin see maven dependencies "without referenced libraries". otherwise, end doing maven -> update project or remove "referenced libraries" manually maven modules.


Comments

Popular posts from this blog

Magento/PHP - Get phones on all members in a customer group -

php - Bypass Geo Redirect for specific directories -

php - .htaccess mod_rewrite for dynamic url which has domain names -