Macro check_latest::check_minor_async[][src]

macro_rules! check_minor_async {
    () => { ... };
}
Expand description

Checks if there is a higher minor version available with the same major version

Returns

Assume the current version is a.b.c, and we are looking at versions that are a.y.z.

  • Ok(Some(version)) if a.y.z > a.b.c where version = max a.b.z
  • Ok(None) if no version meets the rule a.y.z > a.b.c
  • Err(e) if comparison could not be made

Example

use check_latest::check_minor_async;

if let Ok(Some(version)) = check_minor_async!().await {
    println!("A new version is available: {}", version);
}