You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by "Asmann, Roland" <Ro...@adesso.at> on 2011/02/25 16:30:29 UTC
Retrieving all available versions of an artifact
Hi all,
I'm writing a plug-in and currently need a list of all available
versions for a specific artifact. I've found this method:
ArtifactMetadataSource.retrieveAvailableVersions
which I thought would do this. However, this method does not give the
list of available SNAPSHOTs.
In my plug-in I want to make sure that the latest version of a certain
artifact is used. This version may either be the latest release or a
newer SNAPSHOT. But like I said, the method doesn't give me the latest
version of the SNAPSHOTs.
I figured out already, that this is because the implementation of the
above method only checks the remote release repositories. It doesn't
look in the local repository (which in my tests contained the SNAPSHOT I
was looking for) or the remote snapshot repositories.
Does anybody know if there is a method that does exactly what I want, or
am I stuck to defining my snapshot repositories to contain releases as
well? The latter is a workaround that gets me the artifact, but now
Maven tries to resolve all artifacts to that repo as well, and it makes
my build that much slower.
Any help is greatly appreciated!
--
Roland Asmann
Senior Software Engineer
adesso Austria GmbH
Floridotower 26. Stock T +43 1 2198790-27
Floridsdorfer Hauptstr. 1 F +43 1 2198790-927
A-1210 Wien M +43 664 88657566
E roland.asmann@adesso.at
W www.adesso.at
-------------------------------------------------------------
>>> business. people. technology. <<<
-------------------------------------------------------------
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Retrieving all available versions of an artifact
Posted by Wendy Smoak <ws...@gmail.com>.
On Fri, Feb 25, 2011 at 10:30 AM, Asmann, Roland
<Ro...@adesso.at> wrote:
> I'm writing a plug-in and currently need a list of all available
> versions for a specific artifact. I've found this method:
The Codehaus mojo dev list might be a better place to find plugin
developers to ask...
And you might want to look at the Versions Maven Plugin over there, I
think it does something similar:
http://mojo.codehaus.org/versions-maven-plugin/ .
--
Wendy
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org