This is going to be a pretty quick post – I found out about entr relatively recently and I felt like WHY DID NOBODY TELL ME ABOUT THIS BEFORE?!?! So I’m telling you about it in case you’re in the same boat as I was.
There’s a great explanation of the tool with lots of examples on entr’s website.
The summary is in the headline:
entr is a command line tool that lets you run a arbitrary command every time you change any of a set of specified files.