aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Lemon <y@yulqen.org>2024-05-22 09:07:11 +0100
committerMatthew Lemon <y@yulqen.org>2024-05-22 09:07:11 +0100
commitc9db27caa5cdb459e6122e38fc494f169c068ee5 (patch)
tree047734fa4699f177bd56a4e7ad56c4771a76d6dc
parent4562537226fc0afe1b0388d635f65b6141c6f5f2 (diff)
Tinkering with tmux
-rw-r--r--tmux.conf9
1 files changed, 7 insertions, 2 deletions
diff --git a/tmux.conf b/tmux.conf
index 8da0412..3d79765 100644
--- a/tmux.conf
+++ b/tmux.conf
@@ -9,11 +9,16 @@ set-option -g focus-events on
#set -g default-shell '/bin/ksh'
# paste with Ctrl Y
-bind-key -n C-y run "tmux set-buffer \"$(xclip -o -sel clipboard)\"; tmux paste-buffer"
+#bind-key -n C-y run "tmux set-buffer \"$(xclip -o -sel clipboard)\"; tmux paste-buffer"
# command sequence for nested tmux sessions
bind-key a send-prefix
+# Automatically copy selected text to PRIMARY and CLIPBOARD
+bind-key -T copy-mode-vi MouseDragEnd1Pane send-keys -X copy-selection-and-cancel\; run-shell -b "tmux show-buffer | xclip -selection primary -i && tmux show-buffer | xclip -selection clipboard -i"
+bind-key -T copy-mode-vi MouseDragEnd1Pane send-keys -X select-pane \; send-keys -X copy-selection-and-cancel\; run-shell -b "tmux show-buffer | xclip -selection primary -i && tmux show-buffer | xclip -selection clipboard -i"
+bind-key -T copy-mode-vi MouseDragEnd1Pane send-keys -X select-pane \; send-keys -X copy-selection-and-cancel\; run-shell -b "tmux show-buffer | xclip -selection primary -i && tmux show-buffer | xclip -selection clipboard -i"
+
# set prefix key to ctrl-a
set -g prefix C-a
@@ -117,7 +122,7 @@ set -g status-left-length 20
## COLORSCHEME: gruvbox dark (medium) (stolen from github)
## from https://gitlab.com/herrhotzenplotz/unfoofed-dotfiles/-/blob/trunk/homedir/.tmux.conf?ref_type=heads
-set-option -g status-position "top"
+set-option -g status-position "bottom"
set-option -g status "on"
set-option -g status-style bg=colour237,fg=colour223 # bg=bg1, fg=fg1
set-window-option -g window-status-style bg=colour214,fg=colour237 # bg=yellow, fg=bg1