3 ms·
Eh, you don't need tmux hooks for that. Just mkfifo notify.pipe grep 'error' < notify.pipe | notify-macosx-or-whatever >/dev/null & compile-whateve
by cormacrelf 9y ago
Eh, you don't need tmux hooks for that. Just
mkfifo notify.pipe
grep 'error' < notify.pipe | notify-macosx-or-whatever >/dev/null &
compile-whatever | tee notify.pipe
Edit: You can do this WAY more simply with bash >() pipes.
compile | tee >(grep 'error' | notify >/dev/null)
- diggan 9y agoSure, you dont NEED it, but then you don't need a lot of stuff. I guess the value comes from not having to remember all those commands, just enter the hooks in the config and you have those steps happening automatically for you.
- cormacrelf 9y agoThat's kinda what saving as build.sh is for. IMO tmux is much cooler when you do stuff like running commands in or sending text to a different window. Check out entr(1) for some sweet use cases that are much more fun than the hooks. That vimdiff thing ... I used it a few months ago when trying to replicate some complicated rollup.js compiler output options. Awesome, even though I own Kaleidoscope. http://entrproject.org/ http://entrproject.org/