| Crates.io | uptime_lib |
| lib.rs | uptime_lib |
| version | 0.3.1 |
| created_at | 2017-10-08 04:07:15.076216+00 |
| updated_at | 2024-06-28 23:43:55.815867+00 |
| description | Multi-platform uptime library |
| homepage | |
| repository | https://github.com/itchyny/uptime-rs |
| max_upload_size | |
| id | 34785 |
| size | 16,318 |
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);
}
}
}
itchyny (https://github.com/itchyny)
This software is released under the MIT License, see LICENSE.