dotfiles

My collection of dotfiles
git clone git://git.noxz.tech/dotfiles
Log | Files | Refs

commit f238bbdd3531cded2c6b299acda962e9a1b8b4cd
parent 5b9d7adf264098fe1dc925952eb85585e0d7c5df
Author: Chris Noxz <chris@noxz.tech>
Date:   Thu, 10 Oct 2019 18:20:07 +0200

[tmux] Add possibility to move a panes between sessions

Diffstat:
Abin/.bin/fzf-move-to.tmux | 13+++++++++++++
Mtmux/.config/tmux/tmux.conf | 3++-
2 files changed, 15 insertions(+), 1 deletion(-)

diff --git a/bin/.bin/fzf-move-to.tmux b/bin/.bin/fzf-move-to.tmux @@ -0,0 +1,13 @@ +#!/bin/sh + +sessions="$(tmux list-sessions)" + +printf '%s\n' "$sessions" \ + | fzf-tmux \ + -d 35% \ + --exit-0 \ + --cycle \ + --reverse \ + --no-preview \ + | sed -r 's/^([^:]*:).*/\1/g' \ + | xargs -i sh -c 'tmux move-window -t {}99 && tmux move-window -r -t {}' diff --git a/tmux/.config/tmux/tmux.conf b/tmux/.config/tmux/tmux.conf @@ -33,7 +33,7 @@ set -g status-interval 10 # set window titles set -g set-titles on -set -g set-titles-string "#T" +set -g set-titles-string "[#S] #W: #T" ############################################################################# # functionality # @@ -89,6 +89,7 @@ unbind -T prefix c bind -T root M-z resize-pane -Z bind -T prefix w new-window -c "#{pane_current_path}" bind -T prefix u run -b "fzf-url.tmux" +bind -T prefix m run -b "fzf-move-to.tmux" # mouse scrolling unbind -T root WheelUpPane