title: Pipe to/from the clipboard in a Bash script
body: <p>Is it possible to pipe to/from the clipboard in Bash?</p>
  <p>Whether it is piping to/from a device handle or using an auxiliary application, I can't find anything.</p>
  <p>For example, if <code>/dev/clip</code> was a device linking to the clipboard we could do:</p>
  <pre><code>cat /dev/clip        # Dump the contents of the clipboard
  cat foo &gt; /dev/clip  # Dump the contents of &quot;foo&quot; into the clipboard
  </code></pre>