I try to bind two keys under i3 to sync primary selection buffer with clipboard. The definitions are as follows:
bindsym $mod+Shift+b exec "xsel | xsel -b"
bindsym $mod+Shift+p exec "xsel -b | xsel"
The above definition doesn't work in the sense the primary and clipboard buffers are not copied. The same command works if run in a terminal. Tried to wrap the commands into shell scripts. Yet, it still does not work.
bindsym $mod+Shift+b exec p2b.sh
bindsym $mod+Shift+p exec b2p.sh
On the other hand, if I try
bindsym $mod+Shift+b exec echo "xsel | xsel -b" >> ~/.i3debug
Seems the keybinding is activated.
My question is whether there is any deep reason that the cl