I have a bug in my tmux. The status bar randomly transform into two rows (see image below) or disappear completely.
Also, some lines of the terminal command disappear. See image below where the last row disappear.
Does someone know how to solve this issue?
I am using zsh and the same problem appeas in iTerm2 and Kitty.
Here is my tmux config, BTW:
# Window [2]
bind | split-window -h
bind - split-window -v
unbind '"'
unbind %
reload config file (change file location to your the tmux.conf you want to use) [2]
bind r source-file ~/.tmux.conf
Enable mouse mode (tmux 2.1 and above) [2,4,5]
set -g mouse on
bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'select-pane -t=; copy-mode -e; send-keys -M'"
bind -n WheelDownPane select-pane -t= ; send-keys -M
bind -n C-WheelUpPane select-pane -t= ; copy-mode -e ; send-keys -M
bind -T copy-mode-vi C-WheelUpPane send-keys -X halfpage-up
bind -T copy-mode-vi C-WheelDownPane send-keys -X halfpage-down
bind -T copy-mode-emacs C-WheelUpPane send-keys -X halfpage-up
bind -T copy-mode-emacs C-WheelDownPane send-keys -X halfpage-down
To copy, left click and drag to highlight text in yellow,
once you release left click yellow text will disappear and will automatically be available in clibboard
# Use vim keybindings in copy mode
setw -g mode-keys vi
Update default binding of Enter to also use copy-pipe
unbind -T copy-mode-vi Enter
bind-key -T copy-mode-vi Enter send-keys -X copy-pipe-and-cancel "pbcopy"
bind-key -T copy-mode-vi MouseDragEnd1Pane send-keys -X copy-pipe-and-cancel "pbcopy"
Set zsh as default shell in tmux [6]
set-option -g default-shell /bin/zsh
switch panes using Alt-arrow without prefix [2]
bind -n M-Left select-pane -L
bind -n M-Right select-pane -R
bind -n M-Up select-pane -U
bind -n M-Down select-pane -D
Weather [3]
set -g status-interval 60
WEATHER='#(curl -s wttr.in/Sydney?format="%%l:+%%c%%20%%t%%60%%w&period=60")'
set -g status-right "$WEATHER ..."
References
[1] https://gist.github.com/michaellihs/b6d46fa460fa5e429ea7ee5ff8794b96
[2] https://www.hamvocke.com/blog/a-guide-to-customizing-your-tmux-conf/
[3] https://github.com/chubin/wttr.in#one-line-output
[4] https://superuser.com/questions/209437/how-do-i-scroll-in-tmux
[5] https://unix.stackexchange.com/questions/318281/how-to-copy-and-paste-with-a-mouse-with-tmux
[6] https://superuser.com/questions/253786/how-can-i-make-tmux-use-my-default-shell

