Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [m2e-users] Help: how to avoid the exclude pattern=** on a target/generated-sources/foobar directory?

Hi Igor

Le 16/12/2012 18:29, Igor Fedorenko a écrit :
First, m2e never puts excludes=** on generated sources folders. If you
see this happens, some other tool does it, not m2e.
I am quite a bit puzzled by your response... Which knows about the Exclusion Filter of Eclipse except the m2e eclipse plugin? maven and maven plugins are not aware of Eclipse... so... I am puzzled

m2e still needs help to recognize generated sources folder.

The easiest, but somewhat crude, way to do this is to map
foobar-maven-plugin mojo to <execute> with runOnConfiguration=true and
runOnIncremental=false. This will add target/generated-sources/foobar
source folder to project build path, but the sources will only be
(re)generated during full/clean build. To fully support incremental
build, the mojo will need to use BuildContext API. There is more
information this in [1] wiki.

[1] http://wiki.eclipse.org/M2E_compatible_maven_plugins


--
Regards,
Igor

On 2012-12-16 7:14 AM, Francis ANDRE wrote:
Hi m2e users

I understand well why m2e puts an Exclusion Filter=** on any resource
directory to avoid a double copy of the resources, but I am building a
DSL compiler for the "foobar" language and a maven plugin to activate
this compiler under Maven.

As the "foobar" compiler produces java sources in
the_target/generated-sources/foobar_ directory, m2e puts the Exclusion
Filter=** and the generated java code is never compiled by Eclipse.

How can one indicates in the foobar-maven-plugin mojo to avoid adding
the Exclusion Filter for the _target/generated-sources/foobar_ directory ?

Thank in advance for your help.

FA


_______________________________________________
m2e-users mailing list
m2e-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/m2e-users

_______________________________________________
m2e-users mailing list
m2e-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/m2e-users




Back to the top