Unverified Commit cb4b8b16 authored by Eonm's avatar Eonm Committed by GitHub
Browse files

Merge pull request #1 from mvertescher/show_interfaces_example

Add example to print host wireless interfaces
parents 9d233df3 bf27cd2f
//! 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());
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