mhartington
mhartington

Reputation: 7025

Complete active status in tmux

I've been working on reimplementing powerline for tmux using just my tmux.conf instead of python. I have almost all of what I used and needed rebuild except for handling activity statuses.

A window in my tmux sessions gets styled like this:

set-window-option -g window-status-format "#[fg=black, bg=black]⮀#[fg=white, bg=black] #I ⮁ #[fg=blue, bg=black] #W #[fg=black, bg=black]⮀"

Essentially recreating this. https://raw.githubusercontent.com/erikw/tmux-powerline/master/img/left-status.png

But this is what appears to be the only option for activity status.

set-option -gw window-status-activity-attr bold
set-option -gw window-status-activity-bg black
set-option -gw window-status-activity-fg red

Or more along the lines of something like this.

set-option -gw window-status-activity-style fg=red,bg=black,bold

But when I try to incorporate the default formate for my tmux window's, I get this error

~/.tmux.conf:107: bad style

Any ideas?

Edit:

Here's what I'm trying to set for the activity style

set-option -gw window-status-activity-style "#[fg=black, bg=black]⮀#[fg=white, bg=black] #I ⮁ #[fg=blue, bg=black] #W #[fg=black, bg=black]⮀"

Upvotes: 0

Views: 1222

Answers (2)

mhartington
mhartington

Reputation: 7025

Turns out that there there is a flag for this. With complex status bars, you can't simply use window-status-active, but the flag #{?window_activity_flag

See my tmux config

Upvotes: 1

Armali
Armali

Reputation: 19395

you can only set style with comma separated values like "fg=xxx,bg=xxx,bold" what you were trying to do is FORMATS value. – Kent

Upvotes: 0

Related Questions