Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [m2e-users] Cannot edit filtered source files

Well, you are asking for the raw (unfiltered) source files to be on the classpath (so that JDT can work on them) and NOT be on the classpath at the same time, so that they don't clash with the filtering output. Obviously this cannot work. Why are you trying to filter the sources in the first place?


On Tue 03 Jul 2012 08:49:18 AM CEST, Markus Karg wrote:
Hello m2e Community,

I have a problem with filtered source files and I hope you know how to
fix it.

I am editing a simple Java project in Eclipse which worked rather well
until I enabled to filter resources by the following POM entry:












After “Maven > Update Project…” the situation in Eclipse is:

·/target/filtered-sources/java is correctly treated as a derived
source file, i. e. Eclipse warns that all changes are lost as the file
gets recreated automatically by the filtering. I think this is OK and

·But: /src/main/java’s content is shown with a different (shallow) “J”
icon, and Eclipse cannot apply neither “Organize Import” nor “Source >
Format” operations. For example, when trying “Organize Import”,
Eclipse Indigo says “The resource is not on the build path of a Java
project.”. Well, in fact, it actually IS on the build path, but it is
EXCLUDED by “**” by m2e (at least the package explorer tells me). This
means, all the nice JDT gimmicks are switched off!

So editing the original source is rather impossible now! I do not
believe that it is wanted by m2e that I cannot use any of the JDT

What am I doing wrong?



m2e-users mailing list

Back to the top