Monitor a folder for changes, and run a command when a change is detected Is there a simple way to automatically run a (Terminal) command every time a file is changed in a specific folder? 

This should be possible via the command line, or a system built-in application, no third-party applications.

Any ideas?
entr(1) is a utility for running commands when files change. It reads a list of file on STDIN and uses kqueue(2) to avoid polling.

Example:

ls my_project/*.html | entr echo "file changed"