Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

So if a user has the version constraint ">=2.3.3 <2.3.4", should they get that pre-release version?


This is covered explicitly in the SemVer specification section 11[0].

The answer depends on if there exists a released "2.3.3" version, in which case, the pre-release is not selected, because pre-release versions have less priority than release versions.

The spec provides the following example:

1.0.0-alpha < 1.0.0-alpha.1 < 1.0.0-alpha.beta < 1.0.0-beta < 1.0.0-beta.2 < 1.0.0-beta.11 < 1.0.0-rc.1 < 1.0.0.

[0] https://semver.org/#spec-item-11




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: