When hacking on something in a language that’s compiled, some compiles take a long time. So long that it doesn’t make sense to wait and watch it. You can do some lightweight tasks in the meantime - respond to emails, review diffs… The problem is, unless you leave your terminal visible, you won’t know it’s done the moment it is done.
The solution is to send a notification once it’s compiled.
This is not a new idea, iTerm2 has support for notifications from within a
terminal via a special escape code. Problem solved? Kind of. If you only use
iTerm2, then it works like a charm. But if you use a combination of iTerm2