You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Krystian Nowak <kr...@man.poznan.pl> on 2004/12/03 13:35:48 UTC

Re: strategy to retrieve the sources of an maven project

Eric Pugh wrote:
> If what you are looking for is how to download, well I think it's just a
> call to s static method.  Look at ctmsInstall plugin for an example ;-).
> It's not slick, but what you see there is how Maven as well does the
> download, just search for the jellyscript in Maven.
> 
> Now, what we have right now is loading up from a /src/ directory.

I've attached plugin.jelly for maven-eclipse-plugin downloading sources 
from ${repo}/${groupId}/src/${artifactId}-${version}.zip and installing 
it as ${maven.repo.local}/${groupId}/src/${artifactId}-${version}.zip.

It does it for all jar dependencies having eclipse.source property set 
to true. Example project.xml:

(...)
	<dependencies>
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<version>3.8.1</version>
			<url>http://www.junit.org/</url>
			<properties>
				<eclipse.source>true</eclipse.source>
			</properties>
		</dependency>
	</dependencies>
(...)

What you have to do now is to call "maven eclipse" and refresh your 
project in Eclipse.

Have fun!


Regards,
Krystian


-- 
Krystian Nowak
krystian@man.poznan.pl
===========================================
Poznan Supercomputing and Networking Center
Poland, 60-814 Poznan, Zwierzyniecka 20
tel. (+48 61) 8582164 fax. (+48 61) 8582151
http://www.man.poznan.pl
===========================================
BlueEyes - Human-Operator Monitoring System
http://www.blueeyes.prv.pl
http://www.cs.put.poznan.pl/csidc/2001
===========================================

Re: strategy to retrieve the sources of an maven project

Posted by Krystian Nowak <kr...@man.poznan.pl>.
Eric Pugh wrote:
> Can you file a JIRA issue and add a patch file so this doesn't get lost?
> While we have added a bit of support in Eclipse for source code, it has been
> purely for the convenience of the users and doesn't reflect at all how
> future versions of Maven will handle source.  I should probably add a
> disclaimer on the plugin site!

Done!

http://jira.codehaus.org/browse/MPECLIPSE-60



Regards,
Krystian


-- 
Krystian Nowak
krystian@man.poznan.pl
===========================================
Poznan Supercomputing and Networking Center
Poland, 60-814 Poznan, Zwierzyniecka 20
tel. (+48 61) 8582164 fax. (+48 61) 8582151
http://www.man.poznan.pl
===========================================
BlueEyes - Human-Operator Monitoring System
http://www.blueeyes.prv.pl
http://www.cs.put.poznan.pl/csidc/2001
===========================================

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


RE: strategy to retrieve the sources of an maven project

Posted by Eric Pugh <ep...@upstate.com>.
Can you file a JIRA issue and add a patch file so this doesn't get lost?
While we have added a bit of support in Eclipse for source code, it has been
purely for the convenience of the users and doesn't reflect at all how
future versions of Maven will handle source.  I should probably add a
disclaimer on the plugin site!

eRic

> -----Original Message-----
> From: Krystian Nowak [mailto:krystian@man.poznan.pl]
> Sent: Friday, December 03, 2004 1:36 PM
> To: Maven Users List
> Subject: Re: strategy to retrieve the sources of an maven project
>
>
> Eric Pugh wrote:
> > If what you are looking for is how to download, well I think it's just a
> > call to s static method.  Look at ctmsInstall plugin for an example ;-).
> > It's not slick, but what you see there is how Maven as well does the
> > download, just search for the jellyscript in Maven.
> >
> > Now, what we have right now is loading up from a /src/ directory.
>
> I've attached plugin.jelly for maven-eclipse-plugin downloading sources
> from ${repo}/${groupId}/src/${artifactId}-${version}.zip and installing
> it as ${maven.repo.local}/${groupId}/src/${artifactId}-${version}.zip.
>
> It does it for all jar dependencies having eclipse.source property set
> to true. Example project.xml:
>
> (...)
> 	<dependencies>
> 		<dependency>
> 			<groupId>junit</groupId>
> 			<artifactId>junit</artifactId>
> 			<version>3.8.1</version>
> 			<url>http://www.junit.org/</url>
> 			<properties>
> 				<eclipse.source>true</eclipse.source>
> 			</properties>
> 		</dependency>
> 	</dependencies>
> (...)
>
> What you have to do now is to call "maven eclipse" and refresh your
> project in Eclipse.
>
> Have fun!
>
>
> Regards,
> Krystian
>
>
> --
> Krystian Nowak
> krystian@man.poznan.pl
> ===========================================
> Poznan Supercomputing and Networking Center
> Poland, 60-814 Poznan, Zwierzyniecka 20
> tel. (+48 61) 8582164 fax. (+48 61) 8582151
> http://www.man.poznan.pl
> ===========================================
> BlueEyes - Human-Operator Monitoring System
> http://www.blueeyes.prv.pl
> http://www.cs.put.poznan.pl/csidc/2001
> ===========================================
>
>


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