Crates.io | nixinfo |
lib.rs | nixinfo |
version | 0.3.3 |
source | src |
created_at | 2020-08-10 19:58:10.890351 |
updated_at | 2021-03-19 00:56:54.800034 |
description | A lib crate for gathering system info such as cpu, distro, environment, kernel, etc in Rust. |
homepage | https://github.com/Phate6660/nixinfo |
repository | |
max_upload_size | |
id | 275141 |
size | 20,024 |
A lib crate for gathering system info such as cpu, distro, environment, kernel, etc in Rust.
To use: nixinfo = "0.2.8"
in your Cargo.toml
.
nixinfo::cpu()
-> Result<String>
nixinfo::temp()
-> Result<String>
nixinfo::device()
-> Result<String>
nixinfo::distro()
-> Result<String>
nixinfo::environment()
-> Result<String>
nixinfo::env("VARIABLE")
-> Option<String>
lspci
and grep
to be installed for now until I find a pure rust solution)
nixinfo::gpu()
-> Result<String>
nixinfo::hostname()
-> Result<String>
nixinfo::kernel()
-> Result<String>
nixinfo::memory()
-> Result<String>
music
feature to be enabled)
nixinfo::music()
-> String
nixinfo::packages("manager")
-> Result<String>
nixnfo::terminal()
-> Result<String>
nixinfo::uptime()
-> Result<String>