Skip to content

Commit 5733ae7

Browse files
committed
feat(tmux): use a popup and fzf to switch sessions
1 parent 403d0b7 commit 5733ae7

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

config/tmux/tmux.conf

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,13 @@ bind-key g display-popup -w "80%" -h "80%" -d "#{pane_current_path}" -E "lazygit
9494
# toggle the status bar
9595
bind-key -T prefix T set-option -g status
9696

97+
unbind s
98+
bind s display-popup -E "\
99+
tmux list-sessions -F '#{?session_attached,,#{session_name}} ' |\
100+
sed '/^\s*$/d' |\
101+
fzf --reverse --header jump-to-session |\
102+
xargs tmux switch-client -t"
103+
97104
# more settings to make copy-mode more vim-like
98105
unbind [
99106
bind Escape copy-mode

0 commit comments

Comments
 (0)