I am working on a utility that scans USB ports and mounts any storage devices it finds. I can poll the changes (with a fixed version of Ruby-USB), but I would rather get a notification or subscribe to some event.
Is there a way to hack Ruby when a USB drive is inserted?
source
share