Preview of tmux-companionOpen yogesh.lonkar.org

yogesh.lonkar.org/posts/ten-years-of-tmux

tmux-companion

A tmux plugin that replaces multiple #() statusbar programs with a single daemon using Unix sockets and in-memory caching, reducing CPU usage from 15% to ~2% of a core.

Visit project

Show me a random project

First shared
Sep 24, 2026
HN activity
31

Show HN@yogeshlorSep 24, 2026

Show HN: I measured my tmux statusbar at 15% of a core and replaced the forks

tmux status-interval 1 had six #() programs for statusbar, on battery that was 15.4% of a core. After digging found fork+exec through sh -c is ~14.6 ms and computing the actual segments was 2.6 ms on my device. Plus had ~1.5k lines of zsh scripts. Now one deamon process, caches in memory, unix socket and one #() for the whole right side. From 153.77 ms/s → 18.43 ms/s. Made that into a tmux plugin. You can try it without installing/configuring: docker run --rm -it lonkarorg/tmux-companion:playground

Community

Hacker News discussion

Loading the thread…