Hello, Igor,
first of all, thanks for your reply.
Igor Fedorenko-4 wrote:
> What m2e version you are using?
I am using 0.9.7.200902090947. I must admit, that I haven't considered
workspace resolution. You are right, it should indeed apply.
Igor Fedorenko-4 wrote:
> Also, can you check if "my.resource" resource is actually available in
> project output folder (i.e. target/classes).
I'll check this the next time I encounter the problem.
Thanks,
Jochen
--
Regards,
Igor
Jochen Wiedmann wrote:
> Hi,
>
> I have three Maven projects: A produces an artifact, B creates a
> private Maven plugin, and C uses B to process the artifact created by
> A. The plugin accesses the artifacts resources like this:
>
> URL url =
> Thread.currentThread().getContextClassLoader().getResource("my.resource");
> if (url == null) {
> url = getClass().getClassLoader().getResource("my.resource");
> if (url == null) {
> throw new IOException("Resource my.resource not available");
> }
> }
>
> The POM lists the artifact A as a dependency in the plugins section of
> dependencies. In other words, the plugin is configured like this:
>
> <build><plugins>
> <plugin><artifactId>B</artifactId>
> <dependencies><dependency>A</dependency></dependencies>
> </plugin>
> </plugins></build>
>
> This approach works fine within native Maven. Not so within M2Eclipse
> (or, more precisely, when the Maven Project Builder is invoking the
> plugin as a part of the Eclipse build process): The resource isn't
> found.
>
> Any ideas what might be wrong?
>
> Thanks,
>
> Jochen
>
>
>
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email
--
View this message in context:
http://www.nabble.com/Classpath-when-running-Maven-Project-Builder-tp22177949p22197551.html
Sent from the Maven Eclipse - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email