fix: mouse-select copies to system clipboard via pbcopy
Drag-select, y, or Enter in copy-mode all pipe to pbcopy. Holding Option still bypasses tmux for native Terminal.app select.
This commit is contained in:
@@ -31,6 +31,14 @@ set -g pane-active-border-style "fg=#6c5ce7"
|
|||||||
set -g pane-border-status top
|
set -g pane-border-status top
|
||||||
set -g pane-border-format " #{pane_title} "
|
set -g pane-border-format " #{pane_title} "
|
||||||
|
|
||||||
|
# ── Copy / Paste ──────────────────────────────────────────────────────
|
||||||
|
# Mouse-select copies to system clipboard automatically
|
||||||
|
set -g set-clipboard on
|
||||||
|
setw -g mode-keys vi
|
||||||
|
bind -T copy-mode-vi MouseDragEnd1Pane send -X copy-pipe-and-cancel "pbcopy"
|
||||||
|
bind -T copy-mode-vi y send -X copy-pipe-and-cancel "pbcopy"
|
||||||
|
bind -T copy-mode-vi Enter send -X copy-pipe-and-cancel "pbcopy"
|
||||||
|
|
||||||
# ── Quality of Life ───────────────────────────────────────────────────
|
# ── Quality of Life ───────────────────────────────────────────────────
|
||||||
# Easier splits (keep old bindings too)
|
# Easier splits (keep old bindings too)
|
||||||
bind | split-window -h -c "#{pane_current_path}"
|
bind | split-window -h -c "#{pane_current_path}"
|
||||||
|
|||||||
Reference in New Issue
Block a user