i need to run a script every time i plug in my external hard-drive, but i don't want to have to click a file or paste a command into terminal, how can i make sure the script runs as soon as i plug it in?
i need to run a script every time i plug in my external hard-drive, but i don't want to have to click a file or paste a command into terminal, how can i make sure the script runs as soon as i plug it in?
You could write a udev rule (perhaps based on the idVendor and idProduct ATTRS to uniquely identify the device), and give it a RUN action pointing to your script
Grab a fly swatter: https://wiki.ubuntu.com/5-A-Day
Read the New Ubuntu Community Documentation: NewDocs
Try cuttlefish. It does stuff like that!
http://www.omgubuntu.co.uk/2012/09/a...ith-cuttlefish
Bookmarks