M2eclipse: How to set Eclipse project parameters when importing maven project?

Using the m2eclipse Eclipse plugin, each developer should be able to verify the source code, import the Maven project into Eclipse, and have a good go .

I saw that m2eclipse integrates in Eclipse 3.7 and the maven-eclipse-plugin is no longer supported, so I'm looking for a solution based on m2eclipse (without running "mvn eclipse: clean eclipse: eclipse" before importing the project, which makes maven-eclipse- plugin).

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: how would m2eclipse do something like this? In some cases, it’s easy to save the eclipse.settings / prefs file (for example, org.eclipse.jdt.ui.prefs), but in this case com.google.gdt.eclipse.core.prefs is always overwritten when importing the m2eclipse project.

Specific question: asked here , without an answer. Thanks!

UPDATE: now impossible, see request

+4
source share
2 answers

There are answers to this topic in Can I configure m2eclipse via pom.xml? : Fully automatic configuration can only be done using ProjectConfigurator. But there is a solution based on AntRun and XMLTask even for the Google Eclipse Plugin GEP. It is necessary for manual start only once after verification.

+2
source

Try asking your question on the m2eclipse forum on eclipse.org. You will probably reach a much larger number of people familiar with m2eclipse this way.

http://www.eclipse.org/forums/index.php?t=thread&frm_id=61

+1
source

Source: https://habr.com/ru/post/1333787/


All Articles