7 releases (3 stable)

1.1.0 Dec 6, 2024
1.0.1 Jun 11, 2023
1.0.0 Aug 30, 2022
0.9.1 Jun 15, 2022
0.0.2 Jun 5, 2022

#188 in Network programming

Download history 16768/week @ 2024-12-02 16505/week @ 2024-12-09 10091/week @ 2024-12-16 16395/week @ 2024-12-23 16581/week @ 2024-12-30 11425/week @ 2025-01-06 10806/week @ 2025-01-13 14362/week @ 2025-01-20 13799/week @ 2025-01-27 17805/week @ 2025-02-03 24197/week @ 2025-02-10 19324/week @ 2025-02-17 23992/week @ 2025-02-24 24297/week @ 2025-03-03 23852/week @ 2025-03-10 25189/week @ 2025-03-17

100,266 downloads per month

MIT license

11KB
103 lines

wol-rs

main rust-clippy analyze

Wake-on-LAN in rust.

Install

Binary

Download from https://github.com/fengyc/wol-rs/releases.

OR using cargo install

cargo install wol-rs --features bin

OR build from source

cargo install --git https://github.com/fengyc/wol-rs.git --features bin

Run wol -h, to show available options and args.

Wake-on-LAN utility

USAGE:
    wol [OPTIONS] <MAC_ADDR>

ARGS:
    <MAC_ADDR>    Destination MAC address

OPTIONS:
    -b, --bind-addr <BIND_ADDR>      Bind IP address [default: 0.0.0.0]
    -c, --bcast-addr <BCAST_ADDR>    Broadcast IP address [default: 255.255.255.255]
    -h, --help                       Print help information
    -V, --version                    Print version information

ipv6 WoL magic packet can be send by specifying -b and -c with ipv6 address.

Lib

Add wol-rs to Cargo.toml

[dependencies]
wol-rs = "1"

Send a WoL magic packet over UDP

send_wol(<dest_mac>, None, None).unwrap()

License

MIT

Dependencies

~2.3–3.5MB
~63K SLoC