bower使用semver的語法來表示相依性套件該安裝哪一個版本
可參考以下的github資訊
Range Styles
The following range styles are supported:
1.2.3A specific version. When nothing else will do. Must be a full version number, with major, minor, and patch versions specified. Note that build metadata is still ignored, so1.2.3+build2012will satisfy this range.>1.2.3Greater than a specific version.<1 .2.3="" code=""> Less than a specific version. If there is no prerelease tag on the version range, then no prerelease version will be allowed either, even though these are technically "less than".1>>=1.2.3Greater than or equal to. Note that prerelease versions are NOT equal to their "normal" equivalents, so1.2.3-betawill not satisfy this range, but2.3.0-betawill.<=1.2.3Less than or equal to. In this case, prerelease versions ARE allowed, so1.2.3-betawould satisfy.1.2.3 - 2.3.4:=>=1.2.3 <=2.3.4~1.2.3:=>=1.2.3-0 <1 .3.0-0="" code=""> "Reasonably close to1.2.3". When using tilde operators, prerelease versions are supported as well, but a prerelease of the next significant digit will NOT be satisfactory, so1.3.0-betawill not satisfy~1.2.3.1>^1.2.3:=>=1.2.3-0 <2 .0.0-0="" code=""> "Compatible with1.2.3". When using caret operators, anything from the specified version (including prerelease) will be supported up to, but not including, the next major version (or its prereleases).1.5.1will satisfy^1.2.3, while1.2.2and2.0.0-betawill not.2>^0.1.3:=>=0.1.3-0 <0 .2.0-0="" code=""> "Compatible with0.1.3".0.x.xversions are special: the first non-zero component indicates potentially breaking changes, meaning the caret operator matches any version with the same first non-zero component starting at the specified version.0>^0.0.2:==0.0.2"Only the version0.0.2is considered compatible"~1.2:=>=1.2.0-0 <1 .3.0-0="" code=""> "Any version starting with1.2"1>^1.2:=>=1.2.0-0 <2 .0.0-0="" code=""> "Any version compatible with1.2"2>1.2.x:=>=1.2.0-0 <1 .3.0-0="" code=""> "Any version starting with1.2"1>1.2.*Same as1.2.x.1.2Same as1.2.x.~1:=>=1.0.0-0 <2 .0.0-0="" code=""> "Any version starting with1"2>^1:=>=1.0.0-0 <2 .0.0-0="" code=""> "Any version compatible with1"2>1.x:=>=1.0.0-0 <2 .0.0-0="" code=""> "Any version starting with1"2>1.*Same as1.x.1Same as1.x.*Any version whatsoever.xSame as*.""(just an empty string) Same as*.
沒有留言:
張貼留言
留個話吧:)