From c145edc67853f5b590c2206ecf5d43913cd3562c Mon Sep 17 00:00:00 2001 From: Sanchayan Maity Date: Fri, 27 Sep 2024 23:03:36 +0530 Subject: [PATCH] tmux: Fix session selector Not sure what changed in the upgrade to 3.5. This also improves it a bit compared to the previously convoluted incantation we copied from somewhere. --- tmux/.tmux.conf | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/tmux/.tmux.conf b/tmux/.tmux.conf index 7163c8a..7c97981 100644 --- a/tmux/.tmux.conf +++ b/tmux/.tmux.conf @@ -102,11 +102,7 @@ bind -T copy-mode-vi r send-keys -X rectangle-toggle bind S command-prompt -p 'Save history to filename:' -I '/tmp/tmux.history' 'capture-pane -S - -E -; save-buffer %1 ; delete-buffer' # Session selector -bind T display-popup -E "tmux list-sessions -F '#{session_name}' \ - | grep -v \"^$(tmux display-message -p '#S')\$\" \ - | fzf --reverse --exact \ - | sed -E 's/\s-.*$//' \ - | xargs tmux switch-client -t" +bind T display-popup -E "tmux switch-client -t (tmux list-sessions | fzf --exact | awk -F':' '{print $1}')" # Last command output set -g @command-capture-key t