tmux

Tmux: prevent adding 0 to session name


I use tmux a lot, I name the sessions after datasets I process (i.e. GSE272396), it helps me track what I'm dealing with.

However, for some reason tmux adds a 0 to the name in the bottom left of the screen:

enter image description here

Since I identify and compare sessions and datasets based on the last 3 digits or so, this constantly throws me off (enough to come here :)). Is there a way to just set the session name to display as I set it? So without the added 0?


Solution

  • It's not that 0 is added to the session name. Rather, the session name is truncated by default. You can make the columns of the status line longer, by adding this to your .tmux.conf:

    set -g status-left-length 20
    

    Source: How to extend the length of session name in tmux?