2009/9/14 Lewis, Eric <eric.le...@ipi.ch>:
> Hi
>
> I'm a bit confused about these two goals in the Versions Plugin.
>
> For both, the documentation says "Replaces any version with the latest 
> version."
>
> What I want to do is replace "x.y.z-SNAPSHOT" by "x.y.z"
>
> Supposing that my project has a dependency on foo:1.2.3-SNAPSHOT and both 
> foo:1.2.3 and foo:2.0.0 exist as releases in the repo.
>
> My guess is that use-latest-versions changes the dependency to foo:2.0.0 and 
> use-next-versions changes it to foo:1.2.3  - is that correct?
>

yes...

put you probably want:  use-releases....

use-___-versions will consider both -SNAPSHOT and non-SNAPSHOT for any
dependency
use-___-releases will consider only newer releases of only -SNAPSHOT
dependencies
use-___-snapshots will consider only newer -SNAPSHOTs of only release
dependencies

use-next-____ will only consider the next version within the update
scope you specify.
use-latest-___ will only consider the absolute newest version within
the update scope you specify.

the available versions are 1.1.2-SNAPSHOT, 1.1.2, 1.2, 1.2.1, 1.2.2,
1.3, 1.3.1, 1.4, 1.4.1, 2.0, 2.0.1, 2.1.0, 2.2-SNAPSHOT

your current version is 1.1.1

use-next-versions -> 1.1.2-SNAPSHOT (if allowSnapshots, otherwise 1.1.2)
use-latest-versions -> 2.2-SNAPSHOT (if allowSnapshots, otherwise 2.1.0)
use-next-release -> 1.1.2
use-latest-release -> 2.1.0
use-next-snapshots -> 1.1.2-SNAPSHOT
use-latest-snapshots -> 1.1.2-SNAPSHOT (if allowMajorUpdates=false
otherwise 2.2-SNAPSHOT)

use-releases -> 1.1.1 (because it's already a release)

your current version is 1.3-SNAPSHOT

use-next-versions -> 1.3
use-latest-versions -> 2.2-SNAPSHOT (if allowSnapshots, otherwise 2.1.0)
use-next-release -> 1.3
use-latest-release -> 2.1.0
use-next-snapshots -> 1.3-SNAPSHOT (if allowMajorUpdates=false
otherwise 2.2-SNAPSHOT)
use-latest-snapshots -> 1.3-SNAPSHOT (if allowMajorUpdates=false
otherwise 2.2-SNAPSHOT)

use-releases -> 1.3

-Stephen

> Best regards,
> Eric
>
> P.S. The versions plugin is great, but it's kind of hard to make the 
> distinction between all the use-(latest|next)-(releases|snapshots|versions) 
> goals. I mean, what is the difference between a release and a version?
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>

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

Reply via email to