mirror of
https://github.com/tmux-plugins/tmux-yank.git
synced 2026-09-10 07:36:17 -04:00
Detect wayland clipboard
This commit is contained in:
parent
44fc7cc7b5
commit
a7e1d21d7f
|
|
@ -148,7 +148,7 @@
|
|||
fi
|
||||
elif command_exists "clip.exe"; then # WSL clipboard command
|
||||
echo "clip.exe"
|
||||
elif command_exists "xsel"; then
|
||||
elif [ -n "$DISPLAY" ] && command_exists "xsel"; then
|
||||
local xsel_selection
|
||||
if [[ $mouse == "true" ]]; then
|
||||
xsel_selection="$(yank_selection_mouse)"
|
||||
|
|
@ -156,7 +156,7 @@
|
|||
xsel_selection="$(yank_selection)"
|
||||
fi
|
||||
echo "xsel -i --$xsel_selection"
|
||||
elif command_exists "xclip"; then
|
||||
elif [ -n "$DISPLAY" ] && command_exists "xclip"; then
|
||||
local xclip_selection
|
||||
if [[ $mouse == "true" ]]; then
|
||||
xclip_selection="$(yank_selection_mouse)"
|
||||
|
|
@ -164,6 +164,8 @@
|
|||
xclip_selection="$(yank_selection)"
|
||||
fi
|
||||
echo "xclip -selection $xclip_selection"
|
||||
elif command_exists "wl-copy"; then
|
||||
echo "wl-copy"
|
||||
elif command_exists "putclip"; then # cygwin clipboard command
|
||||
echo "putclip"
|
||||
elif [ -n "$(custom_copy_command)" ]; then
|
||||
|
|
|
|||
Loading…
Reference in a new issue