Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

semver syntax: support hyphen ranges #843

Closed
StefanKarpinski opened this issue Oct 18, 2018 · 0 comments · Fixed by #1410
Closed

semver syntax: support hyphen ranges #843

StefanKarpinski opened this issue Oct 18, 2018 · 0 comments · Fixed by #1410

Comments

@StefanKarpinski
Copy link
Member

In #751 it came up that it would be nice if the semver version spec parsing supported 0.7-1 hyphen range support (as the call it in npm). Quoth @KristofferC:

Adding things to

Pkg.jl/src/versions.jl

Lines 340 to 345 in dfb341a

const version = "v?([0-9]+?)(?:\\.([0-9]+?))?(?:\\.([0-9]+?))?"
const ver_regs =
[
Regex("^([~^]?)?$version\$") => semver_interval, # 0.5 ^0.4 ~0.3.2
Regex("^((?:≥)|(?:>=)|(?:=)|(?:<)|(?:=))v?$version\$") => inequality_interval,# < 0.2 >= 0.5,2
]

should be fairly simple.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants