From a74eda082501e45371f2dd228bdf01311ed72e94 Mon Sep 17 00:00:00 2001 From: thek4n Date: Mon, 27 May 2024 13:13:11 +0300 Subject: [PATCH] ref(tmux) --- home/user/.config/tmux/mappings.conf | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/home/user/.config/tmux/mappings.conf b/home/user/.config/tmux/mappings.conf index 538f1bc..124f2c1 100644 --- a/home/user/.config/tmux/mappings.conf +++ b/home/user/.config/tmux/mappings.conf @@ -44,6 +44,15 @@ bind Q kill-window # Kill other windows bind C-q confirm-before -p "kill other windows? (y/n)" "kill-window -a" +# Detach +bind d detach +# Choose client to detach +bind D choose-client -Z +# Detach other clients +bind C-d if -F '#{session_many_attached}' \ + 'confirm-before -p "Detach other clients? (y/n)" "detach -a"' \ + 'display "Session has only 1 client attached"' + bind r command-prompt -I '#W' -p "New window name:" "rename-window '%%'" bind R command-prompt -I '#S' -p "New session name:" "rename-session '%%'" @@ -99,12 +108,6 @@ bind o if -F '#{pane_synchronized}' 'setw synchronize-panes off' 'setw synchroni bind O setw synchronize-panes off -# Detach -bind C-d if -F '#{session_many_attached}' \ - 'confirm-before -p "Detach other clients? (y/n)" "detach -a"' \ - 'display "Session has only 1 client attached"' - - bind i "set -g display-time $_tmux_display_panes_time \; display-message \; display-panes \; set -g display-time $_tmux_display_time"