4

I'm trying to bind control + i to load the contents of file.txt to the clipboard (so that I can use ctrl + v to paste the contents of file.txt into windows like my browser).

The following command works perfectly if I manually type it into a bash terminal:

xsel --clipboard < /home/paul/Dropbox/file.txt

However, when I try to use xbindkeys to do it, it does not. This is what I have in my xbindkeys config:

"xsel --clipboard < /home/paul/Dropbox/file.txt"
   control + i

What could be causing this problem?

PP1211
  • 41
  • 1

1 Answers1

1

The xsel man page says it tests stdin/stdout to see if they are a terminal, and outputs the selection if stdout is not a terminal, so add the option --input to ensure it sets the selection instead.

meuh
  • 49,672
  • 2
  • 52
  • 114