agnat / node_wake_on_lan

Wake-on-LAN utilities for node.js
MIT License
223 stars 24 forks source link

Add bin field to package json #6

Closed mh-cbon closed 6 years ago

agnat commented 8 years ago

I see you got into hacking, beefing up the tiny utility. Nice. :)

First notes:

Ping me when you're happy with everything. Then I'll do a review...

mh-cbon commented 8 years ago

Glad you like it : )

I would like to highlight/suggest few things, btw,

line 63 : I think the callback should be nullified after it was consumed, in order to avoid a double callback invokation. In case node api changes.

Line 19: I guess it can be rewrite to new Buffer(str, 'hex') like in https://nodejs.org/api/buffer.html#buffer_class_method_buffer_bytelength_string_encoding

Also i was thinking to add password, but i m unsure about how to proceed, my best bet would be,

finally, sorry for the package formatting.... My IDE is stubborn about not using front comma's.

edit: I d like very much to add a link to https://wiki.wireshark.org/WakeOnLAN to give a proper resource explaining the format of such packet for noob like me.

agnat commented 6 years ago

I landed this in 04caf7d83a1d030c3e065ba9200730b46954dcc7. Thanks.