Tag: latest-strategies

Defines a list of latest strategies usable in ivy. Each latest strategy is identified by its name, given as an attribute.
The child tag used for the latest strategy must be equal to a name of a latest strategy type (usually added with the typedef tag).

The latest strategies which are always included in ivy (and do not require anything in the configuration file) are:
  • latest-time
  • compares the revisions date to know which is the latest. While this is often a good
    strategy in terms of pertinence, it has the drawback to be costful to compute with distant repositories. If you use ivyrep,
    for example, ivy has to ask the http server what is the date of each ivy file before knowing which is the latest.
  • latest-revision
  • compares the revisions as string, using an algorithm close to the one used in the php version_compare function.
    This algorithm takes into account special meaning of some text. For instance, with this strategy, 1.0-dev1 is considered
    before 1.0-alpha1, which in turn is before 1.0-rc1, which is before 1.0, which is before 1.0.1.
  • latest-lexico
  • compares the revisions as string, using lexicographic order (the one used by java string comparison).

Child elements

any latest strategyadds a latest strategy to the list of available strategies 0..n


since 1.4 The latest-revision can now be configured to handle more words with special meanings than the one defined in php version_compare function.

Here is an example of how you can do so:
<latest-revision name="mylatest-revision">
<specialMeaning name="PRE" value="-2"/>
<specialMeaning name="QA" value="4"/>
<specialMeaning name="PROD" value="5"/>
Knowing that the default special meaning words are the following:
    <specialMeaning name="dev" value="-1"/>
<specialMeaning name="rc" value="1"/>
<specialMeaning name="final" value="2"/>
You can even get rid or redefine the default special meanings by setting usedefaultspecialmeanings="false" on the latest-revision tag.
<latest-revision name="mylatest-revision" usedefaultspecialmeanings="false">
<specialMeaning name="pre" value="-2"/>
<specialMeaning name="m" value="1"/>
<specialMeaning name="rc" value="2"/>
<specialMeaning name="prod" value="3"/>