title: How can I import environment variables from a shell script into the current Ruby environment?
body: <p>I have a series of bash files that I would like to source into the current Ruby environment. Here's an example:</p>
  
  <pre><code>$ echo "export FOO=bar" &gt; foo.sh
  $ irb
  &gt; `source $(pwd)/foo.sh`
  &gt; puts ENV['FOO']
  =&gt; nil
  </code></pre>
  
  <p>Is there a way to source <code>foo.sh</code> into the parent environment without having to manually parse it?</p>