7 unstable releases

0.3.1 Jun 28, 2024
0.3.0 Nov 19, 2023
0.2.2 Aug 1, 2022
0.2.1 Jul 18, 2020
0.0.0 Oct 8, 2017

#128 in Operating systems

Download history 2115/week @ 2024-08-19 1872/week @ 2024-08-26 2277/week @ 2024-09-02 2248/week @ 2024-09-09 1970/week @ 2024-09-16 2161/week @ 2024-09-23 2168/week @ 2024-09-30 1649/week @ 2024-10-07 1579/week @ 2024-10-14 1953/week @ 2024-10-21 1804/week @ 2024-10-28 1645/week @ 2024-11-04 1675/week @ 2024-11-11 2220/week @ 2024-11-18 3094/week @ 2024-11-25 3156/week @ 2024-12-02

10,204 downloads per month
Used in 5 crates

MIT license

6KB
80 lines

Multi-platform uptime library for Rust

CI Status crates.io release MIT License

Example

extern crate uptime_lib;

fn main() {
    match uptime_lib::get() {
        Ok(uptime) => {
            println!("uptime: {} seconds", uptime.as_secs_f64());
        }
        Err(err) => {
            eprintln!("uptime: {}", err);
            std::process::exit(1);
        }
    }
}

Author

itchyny (https://github.com/itchyny)

License

This software is released under the MIT License, see LICENSE.

Dependencies

~0.2–36MB
~542K SLoC