blob: dc5bbad53de92249770ffd197907d5c32e00af3c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
fn main() {
let info = os_info::get();
// Print full information:
println!("OS information: {info}");
// Print information separately:
println!("Type: {}", info.os_type());
println!("Version: {}", info.version());
println!("Edition: {:?}", info.edition());
println!("Codename: {:?}", info.codename());
println!("Bitness: {}", info.bitness());
println!("Architecture: {:?}", info.architecture());
}
|