The Missing Bit

Multitail trick

2021-10-19

I wrote in a previous post that that multitail was nice to have multiple logs in the same terminal window.

I had a small issue, when one of the process dies, the window for it would be closed by multitail.

I ended up thinking of a little trick.

This will ensure the window will stay open until Ctrl-C is hit.

	multitail \
		-cT ansi  -l \
		"bash -c 'make watch || sleep 1d'" \
		-cT ansi -l \
		"bash -c 'make assets-server || sleep 1d'"

It is well suited to things like webpack, that have a tendency to crash when the configuration is changed or cosmic rays lands on it.

With this, the crash log of webpack or any command will stay visible.

If you wish to comment or discuss this post, just mention me on Bluesky or email me.