If you want to use what is going to get expelled from the Maven 3.x
core for all things to use then take a look here:
http://svn.apache.org/repos/asf/maven/components/branches/MNG-2766/maven-repository/src/main/java/org/apache/maven/repository/RepositorySystem.java
Right now in that branch it depends on maven-compat which contains the
resolution code used in 2.x, but the RepositorySystem will have a
Mercury implementation as well. But this interface is meant to serve
as the single point of entry for all things Maven resolution related.
Mercury is a general purpose resolution system and hasn't been
dovetailed exactly with Maven. That will happen as part of a
RepositorySystem implementation that Oleg has been working on in a
branch.
By the end of the week there will be:
repository-system-api
repository-system-legacy
modules which will be self contained that you can use. If you're going
to consume this feedback would be welcome. The goal here was to shore
up much of the dangling public API and create one interface that Maven
3.x uses internally as well as any plugins that require artifact
resolution. The upshot is that 2.x plugins will be able to use this
interface and from the API level nothing will change. I still don't
know how much behavioral characteristics will change as a result of
plugging in Mercury.
If you want Maven specific use the RepositorySystem in that branch
(will go to trunk in a few days), and use Mercury directly if you want
something Maven independent.
Happy to help you out if you want to try it.
On 18-May-09, at 3:46 AM, Alin Dreghiciu wrote:
Alan,
We are implementing at OPS4J Pax URL a simple osgi url handler (that
you
could use also outside osgi) based on Mercury. I started
implementing it a
while ago but then I run into problems with Mercury so was on hold
for a
while. But I will be back on development soon. Once ready the only
thing you
have to do is:
new URL(maven:org.mygroup:myartifact) and so, you get the input
stream of
your jar
If the part where the jar is downloaded into your local repository
is not a
"must" you can use the current "mvn" url handler:
http://wiki.ops4j.org//x/CoA6
On Mon, May 18, 2009 at 7:48 AM, Alan D. Cabrera
wrote:
I need to programatically load jars from the local maven
repository. While
the format of the repository is pretty simple I would like to be
relieved of
the tedium of discovering where this local repository is and, as an
added
bonus, I would love to have jars automatically downloaded to my local
repository if it is not there already.
Can someone point me to the code bits that will help me do this?
Regards,
Alan
-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org
--
Alin Dreghiciu
Software Developer - Looking for new projects!
My profile: http://www.linkedin.com/in/alindreghiciu
My blog: http://adreghiciu.blogspot.com
http://www.ops4j.org - New Energy for OSS Communities - Open
Participation
Software.
http://www.qi4j.org - New Energy for Java - Domain Driven Development.
Thanks,
Jason
--
Jason van Zyl
Founder, Apache Maven
http://twitter.com/jvanzyl
http://twitter.com/SonatypeNexus
http://twitter.com/SonatypeM2E
--
Three may keep a secret if two of them are dead.
-- Benjamin Franklin
-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org