Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions config/tmux-ccb.conf
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,11 @@ if-shell 'command -v pbcopy' {
bind-key -T copy-mode-vi Enter send -X copy-pipe-and-cancel 'pbcopy'
bind-key -T copy-mode-vi MouseDragEnd1Pane send -X copy-pipe-and-cancel 'pbcopy'
}
if-shell 'command -v clip.exe' {
bind-key -T copy-mode-vi 'y' send -X copy-pipe 'clip.exe'
bind-key -T copy-mode-vi Enter send -X copy-pipe-and-cancel 'clip.exe'
bind-key -T copy-mode-vi MouseDragEnd1Pane send -X copy-pipe-and-cancel 'clip.exe'
# WSL: Use PowerShell for clipboard (clip.exe doesn't support UTF-8)
if-shell '[ -n "$WSL_DISTRO_NAME" ] && command -v powershell.exe' {
bind-key -T copy-mode-vi 'y' send -X copy-pipe "powershell.exe -NoProfile -Command 'Set-Clipboard -Value ([Console]::In.ReadToEnd())'"
bind-key -T copy-mode-vi Enter send -X copy-pipe-and-cancel "powershell.exe -NoProfile -Command 'Set-Clipboard -Value ([Console]::In.ReadToEnd())'"
bind-key -T copy-mode-vi MouseDragEnd1Pane send -X copy-pipe-and-cancel "powershell.exe -NoProfile -Command 'Set-Clipboard -Value ([Console]::In.ReadToEnd())'"
}

# Paste from system clipboard (try providers in order; avoids X11/Wayland mis-detection).
Expand Down
Loading