Skip to content

y and Y only work once #103

@WillForan

Description

@WillForan

In the first invocation of tmux (no other servers), y or Y, will copy or add the selection to the prompt. After that, those keys do nothing in copy mode.

  • if I run ~/.tmux/plugins/tmux-yank/yank.tmux, I get one yank. then nothing until I run it again.
  • in copy mode, prefix + ^Y always works (text to system clibpoard).
  • in default mode, prefix + Y always puts PWD on the clipboard

my tmux config is pretty short

# sed 's/#.*//;/^ *$/d' ~/.tmux.conf 
setw -g aggressive-resize on
set -g default-terminal "screen-256color-bce"
set -g mode-keys vi
set -g mouse on
set-environment -g TMUX_PLUGIN_MANAGER_PATH '~/.tmux/plugins/'
set -g @tpm_plugins ' \
 tmux-plugins/tmux-yank   \
 tmux-plugins/tmux-copycat \
'
run-shell "powerline-daemon -q"
source '/usr/share/powerline/bindings/tmux/powerline.conf'
run-shell '/usr/share/tmux-plugin-manager/tpm'

I don't see any conflicting bindings

tmux list-keys|grep Y

bind-key -T copy-mode Y send-keys -X copy-pipe-and-cancel "tmux paste-buffer"
bind-key -T copy-mode-vi Y send-keys -X copy-pipe-and-cancel ""tmux" "paste-buffer""
bind-key -T prefix Y run-shell -b /home/foranw/.tmux/plugins/tmux-yank/scripts/copy_pane_pwd.sh

I think I'm up-to-date

 tmux -V; xsel --version; xclip -version 2>&1|sed 1q; (cd ~/.tmux/plugins/tmux-yank/; git log -n1|sed 1q)

tmux 2.6
xsel version 1.2.0 by Conrad Parker conrad@vergenet.net
xclip version 0.12
commit feb9611

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions