How can I generate-sources on project import/update with m2e - eclipse

I used to add "generate-resources" to Maven's "Goals to run on project import" setting in older m2e.
Now I have new version of eclispe and m2e, and the setting is gone.
How can I add the generated-sources o the eclipse project automatically?
see this older question:
Problems by import of a multiple modules maven 2 project into eclipse workspace
I am using m2e 1.0.200.20111228-1245,
Eclipse version is as follows
Version: Indigo Service Release 2
Build id: 20120216-1857
Maven is: 3.0.4 (r1232337; 2012-01-17 09:44:56+0100)
Pls. note that this is a centrally managed system, I have no root access etc.

Related

How does Eclipse apply an Expose Package configuration to a Maven build?

How does Eclipse propagate Java 11 "Expose Package..." to the Maven target?
I am exposing a Java 11 module to ALL-UNNAMED using Eclipse: Properties -> Java Build Path -> Module Dependencies -> Expose Package...
Nothing is added to pom.xml with this configuration yet the project builds successfully.
Using Eclipse 2020-06, m2e's maven 3.6.3, maven-compiler-plugin 3.8.1 (this is the only explicit override in pom.xml). The rest is the "EMBEDDED" maven.
When I look at the Maven console and effective pom I do not see any compilerArgs (--add-exports...) added. When I run mvn from the command line I do get compiler failure as expected.
How does m2e propagate --add-exports to javac without it being visible to help:effective-pom target or Maven console?
In Eclipse when I click "Show JPMS Options..." it does display "--add-exports ...", but nowhere in the m2e debug output does this appear.

How to use sbt eclipse plugin to put all dependencies in eclipse Library Folder ClasspathContainer?

After I run activator eclipse command and import project into eclipse, we can see all dependencies be separated. I want to put all dependencies(jar) into a Library Folder ClasspathContainer when i run activator eclipse. So how to do it?
Just upgrade eclipse for the latest version.

jbake plugin requires maven upgrade in eclipse

I'm using a maven plugin in my POM file. When I build the project, I get an error:
`[ERROR] Failed to execute goal br.com.ingenieux:jbake-maven-plugin:0.0.9:generate (default-cli) on project uts-documentation: The plugin br.com.ingenieux:jbake-maven-plugin:0.0.9 requires Maven version 3.1.1 -> [Help 1]`
My embedded maven version is 3.0.4. How can I update to the required version without installing a separate instance of maven (would like to avoid that if possible)?
Upgrading to a more recent Eclipse version will bring an updated embedded version of Maven. For example the Eclipse Luna installation that I am running has Maven 3.2.1 embedded.

Error Updating Maven Project under eclipse

I got this error when update Maven Project under eclipse Eclipse Java EE IDE for Web Developers. (Version: Kepler Service Release 2)
An internal error occurred during: "Updating Maven Project".
Path must include project and resource name: /myProjectName
Thanks
rightclick project, remove maven nature (or in newer eclipse, "Maven->Disable Maven Nature")
mvn eclipse:clean (with project open in eclipse/STS)
delete the project in eclipse (but do not delete the sources)
Import existing Maven project
SOLVED THE PROBLEM

Eclipse: Error installing m2e connector for liferay-maven-plugin

When importing a maven project into Eclipse (after installing the maven plugin) I get the following errors:
UNKNOWN HOST: http://releases.liferay.com/tools/ide/latest/stable/compositeContent.xml
softlayer-ams.dl.sourceforge.net
Error installing m2e connector for liferay-maven-plugin contacting repository http://releases.liferay.com/tools/ide/latest/stable/
Should I install Liferay IDE? liferay - http://releases.liferay.com/tools/ide/latest/milestone/
Any ideas?
I installed liferay plugin now I get
Cannot complete the install because of a conflicting dependency.
m2e connector for jaxb2 3.0.0.20130330-0126
m2e connector for mavenarchiver pom properties 0.16.0.201401211452
m2e-liferay - Maven Integration for Liferay IDE 2.0.1.201401270944-ga2
I was able to import the project but now it says:
The container 'Maven Dependencies' references non existing library jnlp-1.6.jar
Solved: Uninstall Eclipse. Then re-install with the needed plugins.
I solved the problem installing "Maven Integration for WTP"
For Eclipse Kepler you can find it here:
http://download.eclipse.org/releases/kepler
m2e-wtp - Maven Integration for WTP (version 1.0.1)
It's inside "Web, XML, Java EE and OSGi..."
This package includes "m2e - Maven Integration for Eclipse" and my problem before was I used to install only this one