You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by "Donald Woods (JIRA)" <de...@geronimo.apache.org> on 2006/06/10 03:18:30 UTC

[jira] Updated: (GERONIMO-1637) Add support for version ranges

     [ http://issues.apache.org/jira/browse/GERONIMO-1637?page=all ]

Donald Woods updated GERONIMO-1637:
-----------------------------------

      Component: Plugins
                     (was: kernel)
    Fix Version: 1.1.1
        Version: 1.1

If we release a 1.1.1, then we need a solution for this in 1.1.1.

How about the following slight modification, so it would also work for -SNAPSHOT or private -REVISION builds?

if (version.equals(gerVersion) ||
    (gerVersion.endsWith("*") &&
     version.startsWith(gerVersion.substring(0, gerVersion.length()-1))) {


The other choice, would be to treat "." and "-" differently, as in

if ( version.equals(gerVersion) ||
     ((gerVersion.endsWith(".*") && version.startsWith(gerVersion.substring(0, gerVersion.length()-2)) ||
     ((gerVersion.endsWith("-*") && version.startsWith(gerVersion.substring(0, gerVersion.length()-2)) ) {

which has the requirement that plugins being developed and tested against -SNAPSHOT builds be rereleased for the final .rcN or 1.N build....


-Donald

Dain Sundstrom wrote:

> On Jun 9, 2006, at 2:13 PM, Aaron Mulder wrote:
>
>> My main objection to that is then there's no way to say "1.1 only".
>> We would have to call 1.1 "1.1.0" so that "1.1" and "1.1.*" would be
>> different.  Or, I suppose, change your patch to gerVersion.length()-1
>> and encourage "1.1*" not "1.1.*"
>
>
>
> I guess my code was bad.  My intention was you could call out  specific versions.  Here is a table of what I wanted to happen:
>
> Input     Version Range
> -----     -------------
> 1.1       1.1
> 1.1.*     [1.1-1.2)
> 1.1.1     1.1.1
> 1.1.1.*   [1.1.1-1.1.2)
>
> and here is the code I posted for those that don't wan to read back  in the thread:
>
> if (version.equals(gerVersion) ||
>         (gerVersion.endsWith(".*" &&
>         version.startsWith(gerVersion.substring(0, gerVersion.length () - 2))) {
>
> With that if statement, the "glob" part of the match only executes if  the version ended with ".*" otherwise it must be an exact match.
>
> -dain
>
>


> Add support for version ranges
> ------------------------------
>
>          Key: GERONIMO-1637
>          URL: http://issues.apache.org/jira/browse/GERONIMO-1637
>      Project: Geronimo
>         Type: Improvement
>     Security: public(Regular issues) 
>   Components: Plugins
>     Versions: 1.1
>     Reporter: Dain Sundstrom
>     Assignee: Dain Sundstrom
>      Fix For: 1.2, 1.1.1

>
> Add support for the version ranges on dependencies.  Should support the full syntax of maven version ranges.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira