Automatic command execution on file changes with entr
Sometimes you want a command to be automatically executed as soon as a certain file changes. There is a small tool called entr, which helps with that.
What's wrong with a simple path unit?
I am not exactly sure what you mean by that... But the main advantage is that the command does not have to be executed manually everytime you change something. Instead entr recognizes when something changes and re-executes the command for you.
entr
That's what a systemd.path unit accomplishes, too. It watches a path, and if that file/directory changes, it starts its accompanying systemd.service.