title: How can I copy the output of the last executed command directly into my clipboard?
body: <p>I have seen this post: <a href="https://stackoverflow.com/questions/5130968/how-can-i-copy-the-output-of-a-command-directly-into-my-clipboard">how-can-i-copy-the-output-of-a-command-directly-into-my-clipboard</a></p>
  
  <p>I have got this alias</p>
  
  <pre><code># Redoes the last command and copies the output to clipboard
  
    alias cl="fc -e -|pbcopy"
  </code></pre>
  
  <p>However I would like an alias or a function that <strong>doesn't redo the last command</strong>, but does copy the output of the last command.</p>