m2eclipse: How to set Eclipse project settings when importing a maven project?
Posted
by
Marius Andreiana
on Stack Overflow
See other posts from Stack Overflow
or by Marius Andreiana
Published on 2010-12-30T11:56:17Z
Indexed on
2011/01/01
9:53 UTC
Read the original article
Hit count: 273
Using m2eclipse Eclipse plugin, everybody on the dev team should be able to checkout source code, import Maven project in Eclipse and be good to go.
I saw m2eclipse is being merged into Eclipse 3.7, and maven-eclipse-plugin won't be maintained any longer, so I'm looking for a m2eclipse-based solution (without running "mvn eclipse:clean eclipse:eclipse" before project import, which is what maven-eclipse-plugin does).
maven-eclipse-plugin allows this in pom.xml
<additionalConfig>
<file>
<name>.settings/com.google.gdt.eclipse.core.prefs</name>
<content><![CDATA[
eclipse.preferences.version=2
jarsExcludedFromWebInfLib=
warSrcDir=${project.build.directory}/${project.build.finalName}
warSrcDirIsOutput=true
]]>
</content>
</file>
The more general question is How would m2eclipse do something similar? For some cases, just saving the eclipse .settings/prefs file works (e.g. org.eclipse.jdt.ui.prefs), but in this case, com.google.gdt.eclipse.core.prefs is always overwritten on m2eclipse project import.
A specific question is asked here, with no reply. Thanks!
UPDATE: Not possible now, see request
© Stack Overflow or respective owner