0

I have a script that operates on enormous files and outputs an enormous amount of content (almost 7000 lines). I need to copy the output of this to my clipboard so I can then paste it into paste2.org and make a paste. Is there a way for me to directly copy the output to my clipboard? Some operation like that of redirection for the clipboard?

1

2 Answers 2

2

You can use the tools xsel or xclip to translate from X clipboard to stdin/stdout on a terminal. If these aren't installed, they're usually available through your distro's package manager. See the man page for the relevant tool to get details on invocation.

1
  1. Use file redirection to save standard out to a temporary file such as /tmp/o

    $ script.sh > /tmp/o

  2. Open browser such as Firefox/Iceweasel, to address: /tmp/o

  3. Now select all, copy and paste to Pastebin.org

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.