You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Martin Burger <m...@rtin-burger.de> on 2005/06/30 09:20:35 UTC

[Eclipse Plugin] Defining dependency as Eclipse project

Hello,

I tried to define an Eclipse project as dependency in the project.xml. 
But after calling "maven eclipse" maven tries to download a JAR instead 
of adding an entry to the .classpath file. I used the sample code at 
http://maven.apache.org/reference/plugins/eclipse/. Did I misunderstand 
something? I thought thats the way to
add a required project to the build path using maven.

Regards,
    Martin


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: [Eclipse Plugin] Defining dependency as Eclipse project

Posted by Marcell Manfrin Barbacena <ba...@gmail.com>.
I agree with you that the docs are misleading...

Try that then:

maven.eclipse.classpath.include=${maven.eclipse.workspace}/project

[]'s

On 6/30/05, Martin Burger <m...@rtin-burger.de> wrote:
> Marcell Manfrin Barbacena schrieb am 30.06.2005 10:02:
> 
> >However, you can add an Eclipse project to the classpath
> >by defining the following in your project.properties file:
> >
> >maven.eclipse.classpath.include=/test1
> >
> >
> 
> This adds E:/test1 to the .classpath as classpathentry (note the drive
> letter).
> 
> BTW, I think the documentation on
> http://maven.apache.org/reference/plugins/eclipse/ is misleading.
> 
> Regards,
>    Martin
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 
> 


-- 
"Nobody knows who i really am
 I never felt this empty before
 And if I never need someone to come along
 Who's gonna comfort me and keep me strong?"
--
Marcell Manfrin Barbacena
barbacena@gmail.com
MSN Messenger: marcell84bruk@hotmail.com
ICQ UIN: 63671762
Skype: callto://marcell84bruk
+55 (83) 8808-8555 (Oi)

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: [Eclipse Plugin] Defining dependency as Eclipse project

Posted by Martin Burger <m...@rtin-burger.de>.
Marcell Manfrin Barbacena schrieb am 30.06.2005 10:02:

>However, you can add an Eclipse project to the classpath
>by defining the following in your project.properties file:
>
>maven.eclipse.classpath.include=/test1
>  
>

This adds E:/test1 to the .classpath as classpathentry (note the drive 
letter).

BTW, I think the documentation on 
http://maven.apache.org/reference/plugins/eclipse/ is misleading.

Regards,
    Martin



Re: [Eclipse Plugin] Defining dependency as Eclipse project

Posted by Marcell Manfrin Barbacena <ba...@gmail.com>.
Im quoting the answer of Tomas for about the same question i made few
months ago:
...
eclipse.dependency does not refer to an Eclipse project but only tells
the Eclipse plugin whether it should add the dependency to the
project's classpath.  Since an Eclipse project is not recognized as a
dependency type, the dependency you have defined will not be
considered as an Eclipse project and automatically added to the
classpath.  However, you can add an Eclipse project to the classpath
by defining the following in your project.properties file:

maven.eclipse.classpath.include=/test1

Then you also need set eclipse.dependency to false in your
project.xml.  If not, you'll add it once as an Eclipse dependency and
a second time as jar dependency.
...

As you can see eclipse.dependency will download the jar and work with
it only for other maven goals but in your eclipse project will be
linked the eclipse project where the property was set.

Best regards.

[]'s

On 6/30/05, Edmund Urbani <em...@liland.org> wrote:
> Martin Burger wrote:
> 
> > Hello,
> >
> > I tried to define an Eclipse project as dependency in the project.xml.
> > But after calling "maven eclipse" maven tries to download a JAR
> > instead of adding an entry to the .classpath file. I used the sample
> > code at http://maven.apache.org/reference/plugins/eclipse/. Did I
> > misunderstand something? I thought thats the way to
> > add a required project to the build path using maven.
> >
> > Regards,
> >    Martin
> >
> The maven eclipse plugin just includes the artifacts from the maven
> repository for you. It does not create dependencies between eclipse
> projects (even though this would be desirable for SNAPSHOT
> dependencies). AFAIK this can't be done with the current eclipse plugin,
> because it does not know about the other projects in your eclipse
> workspace and their locations in the filesystem.
> 
> Maybe Maven 2.0 can do that. I'm waiting for the first beta release
> before I give it a try.
> 
>  Edmund
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 
> 


-- 
"Nobody knows who i really am
 I never felt this empty before
 And if I never need someone to come along
 Who's gonna comfort me and keep me strong?"
--
Marcell Manfrin Barbacena
barbacena@gmail.com
MSN Messenger: marcell84bruk@hotmail.com
ICQ UIN: 63671762
Skype: callto://marcell84bruk
+55 (83) 8808-8555 (Oi)

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: [Eclipse Plugin] Defining dependency as Eclipse project

Posted by Martin Burger <m...@rtin-burger.de>.
Edmund Urbani schrieb am 30.06.2005 09:36:

>The maven eclipse plugin just includes the artifacts from the maven
>repository for you. It does not create dependencies between eclipse
>projects (even though this would be desirable for SNAPSHOT
>dependencies). AFAIK this can't be done with the current eclipse plugin,
>because it does not know about the other projects in your eclipse
>workspace and their locations in the filesystem.
>

Mmh, quoted from http://maven.apache.org/reference/plugins/eclipse/:

" The dependencies defined in the POM need not to be jars strictly. They 
can be projects in the eclipse workspace. If a dependency is an eclipse 
project a property needs to be added to that dependency to indicate so."

"They can be projects in the eclipse workspace." Does this not say that 
it's possible to add a project instead of a JAR?

Regards
    Martin



Re: [Eclipse Plugin] Defining dependency as Eclipse project

Posted by Edmund Urbani <em...@liland.org>.
Martin Burger wrote:

> Hello,
>
> I tried to define an Eclipse project as dependency in the project.xml.
> But after calling "maven eclipse" maven tries to download a JAR
> instead of adding an entry to the .classpath file. I used the sample
> code at http://maven.apache.org/reference/plugins/eclipse/. Did I
> misunderstand something? I thought thats the way to
> add a required project to the build path using maven.
>
> Regards,
>    Martin
>
The maven eclipse plugin just includes the artifacts from the maven
repository for you. It does not create dependencies between eclipse
projects (even though this would be desirable for SNAPSHOT
dependencies). AFAIK this can't be done with the current eclipse plugin,
because it does not know about the other projects in your eclipse
workspace and their locations in the filesystem.

Maybe Maven 2.0 can do that. I'm waiting for the first beta release
before I give it a try.

 Edmund


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org