brewedbits.dev

Personal blog with guides and news on selfhosting, Linux and AI, from the Netherlands

nextDash nextdash --aboutYour bookmarks. Your terminal. checks your links knows your Docker host one container, no cloudLive demo →nextdash.cc ↗

Tip: setw -g monitor-activity on flags tmux windows that print something

Tmux
~/tips/tip-tmux-monitor-activity

setw -g monitor-activity on

Marks a window in the status bar when something new appears in it while you look elsewhere.

Waiting for a build in another window? Let tmux tell you when it prints something.

setw -g monitor-activity on

When a window you are not looking at prints output, its entry in the status bar gets a # and a different colour. Visit the window and the mark goes away.

It flags any output, so a window that prints constantly marks itself all the time. That is fine for a build and noisy for a log that scrolls every second.

Add set -g visual-activity on if you also want a short message in the status line. monitor-silence 30 does the reverse and flags a window that has been quiet for 30 seconds.

Try it without risk: start a throwaway session with tmux new -s scratch, use the shortcut or command above there, look at what changes, and close it again with tmux kill-session -t scratch. Nothing else on your machine is touched.

Further reading: tmux manual page (OpenBSD, official), tmux wiki: Getting Started (official)

More Tmux tips tmux new -d -s report -x 200 -y 50 'top' tmux wait-for build-done set -g allow-passthrough on tmux kill-server Ctrl-b [ All Tmux tips (125) All topics

Link