Is there a way to say "get the latest version" in the project.xml file?

View: New views
3 Messages — Rating Filter:   Alert me  

Is there a way to say "get the latest version" in the project.xml file?

by laredotornado :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

I'm using Maven 1.1.  I have this dependency in my test/project.xml file ...

    <dependency>
        <groupId>myco.dor.dmv.driver.matching</groupId>
        <artifactId>myco-dor-dmv-driver-matching-client</artifactId>
        <version>${pom.currentVersion}</version>
    </dependency>

However, there is no "${pom.currentVersion}" of this particular dependency at this time.  Is there a way to say "get the latest version" without hard-coding the version?  Not sure how maven would know, but I thought I'd through it out here to the experts.

Thanks,  - Dave

Re: Is there a way to say "get the latest version" in the project.xml file?

by mjremijan :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

In your dependency, you might be able to do something like this:

<version>[0.0.1,)</version>

which means any version greater than or equal to 0.0.1.  However, this depends on your Maven version because I think it's relatively new.




________________________________
From: laredotornado <laredotornado@...>
To: users@...
Sent: Mon, November 2, 2009 10:54:45 AM
Subject: Is there a way to say "get the latest version" in the project.xml file?


Hi,

I'm using Maven 1.1.  I have this dependency in my test/project.xml file ...

    <dependency>
        <groupId>myco.dor.dmv.driver.matching</groupId>
        <artifactId>myco-dor-dmv-driver-matching-client</artifactId>
        <version>${pom.currentVersion}</version>
    </dependency>

However, there is no "${pom.currentVersion}" of this particular dependency
at this time.  Is there a way to say "get the latest version" without
hard-coding the version?  Not sure how maven would know, but I thought I'd
through it out here to the experts.

Thanks,  - Dave
--
View this message in context: http://old.nabble.com/Is-there-a-way-to-say-%22get-the-latest-version%22-in-the-project.xml-file--tp26157739p26157739.html
Sent from the Maven - Users mailing list archive at Nabble.com.


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

Re: Is there a way to say "get the latest version" in the project.xml file?

by ltheussl :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


There is no way to do that in maven 1.x (and for a good reason). See
http://maven.apache.org/maven-1.x/using/managing-dependencies.html#Using_SNAPSHOT_Dependencies

HTH,
-Lukas


laredotornado wrote:

> Hi,
>
> I'm using Maven 1.1.  I have this dependency in my test/project.xml file ...
>
>     <dependency>
>         <groupId>myco.dor.dmv.driver.matching</groupId>
>         <artifactId>myco-dor-dmv-driver-matching-client</artifactId>
>         <version>${pom.currentVersion}</version>
>     </dependency>
>
> However, there is no "${pom.currentVersion}" of this particular dependency
> at this time.  Is there a way to say "get the latest version" without
> hard-coding the version?  Not sure how maven would know, but I thought I'd
> through it out here to the experts.
>
> Thanks,  - Dave

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