diff options
| author | harryoooooooooo <ymsc27884@gmail.com> | 2020-12-28 23:04:00 +0800 |
|---|---|---|
| committer | harryoooooooooo <ymsc27884@gmail.com> | 2020-12-28 23:04:00 +0800 |
| commit | 96df051ea399fc2f97651f7aa90a3fdcaa6e41b4 (patch) | |
| tree | 6b80f04dbcd8f9bdaa8c5af9cf62f190c5b1871c | |
| parent | 6c4c28fd02770708705503f3a68584769427782d (diff) | |
tmux-focus: Add support for focusing a client on another window.
| -rw-r--r-- | rc/windowing/tmux.kak | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/rc/windowing/tmux.kak b/rc/windowing/tmux.kak index 8e4c7134..420e6381 100644 --- a/rc/windowing/tmux.kak +++ b/rc/windowing/tmux.kak @@ -55,7 +55,10 @@ If no client is passed then the current one is used' \ if [ $# -eq 1 ]; then printf "evaluate-commands -client '%s' focus" "$1" elif [ -n "${kak_client_env_TMUX}" ]; then - TMUX="${kak_client_env_TMUX}" tmux select-pane -t "${kak_client_env_TMUX_PANE}" > /dev/null + # select-pane makes the pane active in the window, but does not select the window. Both select-pane + # and select-window should be invoked in order to select a pane on a currently not focused window. + TMUX="${kak_client_env_TMUX}" tmux select-window -t "${kak_client_env_TMUX_PANE}" \; \ + select-pane -t "${kak_client_env_TMUX_PANE}" > /dev/null fi } } |
