Crates.io | loose-semver |
lib.rs | loose-semver |
version | 1.1.0 |
created_at | 2025-05-01 14:38:00.294816+00 |
updated_at | 2025-05-03 18:49:37.788276+00 |
description | Loose parser for Semantic Versioning |
homepage | |
repository | https://github.com/zekrotja/loose-semver |
max_upload_size | |
id | 1656343 |
size | 23,469 |
[!WARNING]
This package does not provide a spec-accurate implementation of Semantic Versioning. If you are looking for something like that, please take a look at the semver or semver-rs packages.
This crate allows to parse "semantic versions" that are not formatted exactly like spec. For example, the version scheme used by Go or Minecraft is an example for this.
This crate allows to parse versions following the Sematic Version spec as well as formats like the following examples:
v1.2
3.4.5beta1
2.3-alpha.3
5-rc.1.2.3
use loose_semver::Version;
fn main() {
let v: Version = "1.2.3rc4".parse().unwrap();
dbg!(v);
}