nordtheme / tmux

An arctic, north-bluish clean and elegant tmux color theme.
https://www.nordtheme.com/ports/tmux
MIT License
1.06k stars 141 forks source link

make the status bar responsive #76

Open bbigras opened 1 year ago

bbigras commented 1 year ago

With termux on phones, the status bar could be more optimal.

Currently, I'm using this. Based on https://coderwall.com/p/trgyrq/make-your-tmux-status-bar-responsive .

tmux-airline.sh

#!/usr/bin/env bash

WIDTH=${1}
SMALL=80

if [ "$WIDTH" -le "$SMALL" ]; then
    echo ""
else
    echo "#{prefix_highlight}#[fg=cyan,bg=black,nobold,noitalics,nounderscore]#[fg=black,bg=cyan,bold] #H "
fi

conf

set -g status-right '#(eval ${tmux-airline} `tmux display -p "#{client_width}"`)'
bbigras commented 1 year ago

before: image

after: image