Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[m2e-users] Maven plugin and calling buildContext.refresh(File)

Hi All

I have Maven plugin defining custom "play" packaging (for Play!
Framework 1.x http://www.playframework.com/) applications.
In latest release I added M2Eclipse integration
(see
http://maven-play-plugin.googlecode.com/svn/tags/plugin-1.0.0-beta7/play-maven-plugin/src/main/resources/META-INF/m2e/lifecycle-mapping-metadata.xml)
I've read about BuildContext usage here:
https://wiki.eclipse.org/M2E_compatible_maven_plugins , but I have some
questions related to this functionality.

1. I wanted to test/debug "buildContext.refresh( someFile )" so I ran
Maven builds inside Eclipse, but I've always had the default
"org.sonatype.plexus.build.incremental.DefaultBuildContext"
implementation when I've debugged my code.
What should I do to get M2Eclipse implementation of BuildContext interface:
org.eclipse.m2e.core.internal.builder.EclipseBuildContext
org.eclipse.m2e.core.internal.builder.EclipseIncrementalBuildContext
?

2. Sources and resources are processed by M2E completely differently. Is
calling "refresh" important for sources, resources or both, and why
(why not calling "refresh()" can lead to infinite rebuilds)?

I have some more questions, but I would like to receive responses for
the above two first. Thank you in advance.

Regards

Grzegorz Slowikowski


Back to the top