catppuccin/tmux

Mosh vs SSH status bar rendering

Closed this issue · 2 comments

Is there an existing issue outlining your problem?

  • I have searched the existing issues and they do not solve my problem.

Describe your problem.

I run tmux on a remote Linux host, and when using mosh to connect to the server, the rendering of the tmux status bar wraps.

image

Connecting via ssh, it renders correctly.

image

I'd say it's more of a mosh problem than a configuration one, but raising the issue in case someone has come across this before and can provide any insights in using this theme along with mosh.

Paste your configuration.

I've provided the catppuccin configuration section of my .tmux.conf file, but the entire contents can be provided if it's of benefit.

# catppuccin theme (https://github.com/catppuccin/tmux)
set -g @plugin 'catppuccin/tmux'
set -g @catppuccin_flavour 'mocha'
## window settings
set -g @catppuccin_window_left_separator ""
set -g @catppuccin_window_right_separator " "
set -g @catppuccin_window_middle_separator "█ "
set -g @catppuccin_window_default_fill "number"
set -g @catppuccin_window_default_text "#W"
set -g @catppuccin_window_current_fill "number"
set -g @catppuccin_window_current_text "#W"
set -g @catppuccin_window_status_enable "yes"
set -g @catppuccin_window_status_icon_enable "yes"
## pane settings
set -g @catppuccin_pane_active_border_style '#{?pane_in_mode,fg=#{thm_yellow},#{?synchronize-panes,fg=#{thm_red},fg=#{thm_blue}}}'
## status settings
set -g @catppuccin_status_modules_left "session"
set -g @catppuccin_status_modules_right "date_time"
set -g @catppuccin_status_left_separator  " "
set -g @catppuccin_status_right_separator " "
set -g @catppuccin_status_fill "icon"
set -g @catppuccin_status_connect_separator "no"
## module settings
set -g @catppuccin_date_time_text "%d-%m-%Y %H:%M"

Attach screenshots.

No response

What tmux version are you seeing the issue on?

tmux 3.3a

Any additional comments?

I'm using the following terminal and font.

  • Warp terminal (v0.2024.05.28.08.02.stable_00)
  • MonaspiceAr Nerd Font Mono (font size: 13, line height 1.2)

I've tried iTerm2 and different fonts/line heights, but it hasn't made a difference to the status wrapping.

vdbe commented

It does not only wrap around see the 4, from what is that 4 even? The bar wouldn't even need to wrap without it (if you ignore that tmux would just shift status right 1 char to the left).

Possible (untested) clean solution experiment with some set -g default-terminal and set -ga terminal-overrides combinations in your tmux config.

Hacks that might work (no idea don't use must/know how it works) adding a space at the end of the status bar maybe something like this (again untested):
set -Fg 'status-format[0]' '#{status-format[0]}<add here padding>'/set -Fg 'status-format' '#{status-format}<add here padding>' (syntax is from here https://unix.stackexchange.com/a/680462) might need to change the fg/bg styling so that mosh sees it as empty space with #[fg=<some color/default?>,bg=<some color/default?>,nobold,nounderscore,noitalics].

There are many issues for tmux/other TUI applications on mosh ask it there.

Thanks for getting back to me @vdbe. I'll close the issue, and continue to play around with my configuration to see if I can get something workable. Should I find something, I'll post back here for others that come on by.