cross-uname

Crates.iocross-uname
lib.rscross-uname
version0.1.0
sourcesrc
created_at2024-06-19 07:15:17.448018
updated_at2024-06-19 07:15:17.448018
descriptioncross-uname
homepagehttps://github.com/ahaoboy/cross-uname
repositoryhttps://github.com/ahaoboy/cross-uname
max_upload_size
id1276601
size3,105
阿豪 (ahaoboy)

documentation

README

cross-uname

Get name and information about current kernel by uname command

use cross_uname::uname;

fn main() {
    let info = uname().unwrap();
    // Print the hostname
    println!("{}", info.nodename);
    // Print everything
    println!("{:?}", info);
}

Commit count: 4

cargo fmt