Commit bf27cd2f authored by Matt Vertescher's avatar Matt Vertescher
Browse files

Add example to print host wireless interfaces

parent 238870d3
//! Pretty print host interfaces.
use nl80211::Socket;
use nl80211::PrettyFormat;
fn main() -> Result<(), neli::err::NlError> {
let interfaces = Socket::connect()?.get_interfaces_info()?;
for interface in interfaces {
println!("{}\n", interface.pretty_format());
}
Ok(())
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment