Expand description
§Gem version
§What
Implement Ruby’s Gem::Version
comparison logic in Rust:
The main use case is for the Heroku Ruby buildpack https://github.com/heroku/buildpacks-ruby and associated ecosystem of managing Ruby logic inside of Rust.
§Install
Add it to your cargo.toml:
$ cargo add gem_version
§Use
use std::str::FromStr;
use gem_version::GemVersion;
let version = GemVersion::from_str("1.0.0").unwrap();
assert!(version < GemVersion::from_str("2.0.0").unwrap());
Structs§
- GemVersion
- See module docs for a usage example