How to trigger a script on pi 3?

In addition to the triggers having issues, I did modify that a few times. Double check that you have the current code that’s in the post above. As I thought about it I added a couple lines.