'How to launch bash script on Raspberry Pi once it connects to a usb port?

We are writing a script on a Raspberry Pi that automatically launches a bash script which runs some python scripts to collect info from a usb port. Is there a solution to launch a bash script once it connects to a usb port?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source