title: Pipe Ipython magic output to a variable?
body: <p>I want to run a bash script in my ipython Notebook and save the output as a string in a python variable for further manipulation. Basically I want to pipe the output of the bash magic to a variable,
  For example the output of something like this:</p>
  
  <pre><code>%%bash
  some_command [options] foo bar
  </code></pre>