libiw-async

Crates.iolibiw-async
lib.rslibiw-async
version0.3.0
sourcesrc
created_at2024-10-27 14:18:06.044769
updated_at2024-10-27 15:05:50.755765
descriptionlinux iw command wrapper for async
homepage
repositoryhttps://gitee.com/zr233/libiw
max_upload_size
id1424667
size103,419
周睿 (ZR233)

documentation

README

A lib of Linux iw command

Example

use libiw_async::*;

let iw = IW::new().await.unwrap();

let mut list = iw.interface_list().await.expect("no nic");
for card in &list {
    println!("ifname: {}", card);
}

let interface = list.remove(0);

println!("scan ...");
let mut ap_list = iw.scan(&interface).await.unwrap();
if let Some(ssid) = args.ssid {
    ap_list.retain(|one| one.ssid.contains(&ssid));
}
for one in ap_list {
    println!("{}", one);
}
Commit count: 0

cargo fmt