A. semver.satisfies('~1.2.3', '1.2.4') => true
B. semver.satisfies('~1.2', '1.3.0') => false
C. semver.satisfies('~1.2', '1.2.6') => true
D. semver.satisfies('1.2', '1.3.0') => false
E. semver.satisfies('1.2', '1.2.4') => true

My understanding is similar to Forrest's. ~1.2.3 means 1.2.3 <= version <
1.3.0, whereas ~1.2 means 1.2.0 <= version < 1.3.0

With Forrest's explanation, semver.satisfies('~1.2.3', '1.2.1') would be
true, whereas I would expect it to be false. +1 for the "squishiness",
however, but I prefer that as an indicator to NPM that patch updates are
acceptable while still guaranteeing all the patches in 1.2.3 are present.


On Thu, May 30, 2013 at 2:24 PM, Jake Verbaten <rayn...@gmail.com> wrote:

> A. semver.satisfies('~1.2.3', '1.2.4')
>
> yes
>
>
> B. semver.satisfies('~1.2', '1.3.0')
>
> yes
>
>
> C. semver.satisfies('~1.2', '1.2.6')
>
> yes
>
>
> D. semver.satisfies('1.2', '1.3.0')
>
> no
>
>
> E. semver.satisfies('1.2', '1.2.4')
>
> no
>
>
> On Thu, May 30, 2013 at 1:45 PM, Kevin Swiber <kswi...@gmail.com> wrote:
>
>>
>> On May 30, 2013, at 3:52 PM, Dominic Tarr <dominic.t...@gmail.com> wrote:
>>
>> > without looking in the documentation or trying it in the repl
>> >
>> > what do you expect to be the results of these tests on semver ranges?
>> >
>> > A. semver.satisfies('~1.2.3', '1.2.4')
>> >
>> > B. semver.satisfies('~1.2', '1.3.0')
>> >
>> > C. semver.satisfies('~1.2', '1.2.6')
>> >
>> > D. semver.satisfies('1.2', '1.3.0')
>> >
>> > E. semver.satisfies('1.2', '1.2.4')
>> >
>> > please don't look at the documentation, the question is:
>> >
>> > what do you think it means?
>>
>>
>> I'd prefer to be very explicit:
>>
>> >=1.2.0 <2.0.0
>>
>> I read this as "allow version 1.2.0 or any subsequent version prior to a
>> major API change."
>>
>> I think this is what the tilde implies, but I would have to look it up
>> more than onceā€¦ and so would my fellow collaborators, I imagine.
>>
>> --
>> Kevin Swiber
>> @kevinswiber
>> https://github.com/kevinswiber
>>
>> --
>> --
>> Job Board: http://jobs.nodejs.org/
>> Posting guidelines:
>> https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
>> You received this message because you are subscribed to the Google
>> Groups "nodejs" group.
>> To post to this group, send email to nodejs@googlegroups.com
>> To unsubscribe from this group, send email to
>> nodejs+unsubscr...@googlegroups.com
>> For more options, visit this group at
>> http://groups.google.com/group/nodejs?hl=en?hl=en
>>
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "nodejs" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to nodejs+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>>
>>
>  --
> --
> Job Board: http://jobs.nodejs.org/
> Posting guidelines:
> https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
> You received this message because you are subscribed to the Google
> Groups "nodejs" group.
> To post to this group, send email to nodejs@googlegroups.com
> To unsubscribe from this group, send email to
> nodejs+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/nodejs?hl=en?hl=en
>
> ---
> You received this message because you are subscribed to the Google Groups
> "nodejs" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to nodejs+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to nodejs@googlegroups.com
To unsubscribe from this group, send email to
nodejs+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to nodejs+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to