title: Combine shell and python code
body: <p>Currently, I have following code works:</p>
  
  <p><strong>a.sh</strong></p>
  
  <pre><code>echo "start"
  
  export abc="hello"
  a=`python a.py`
  echo $a
  
  echo "end"
  </code></pre>
  
  <p><strong>a.py</strong></p>
  
  <pre><code>import os
  print os.getenv('abc')*2
  </code></pre>
  
  <p>Above, my shell script need one python script' help to handle something then back the answer to shell script.</p>
  
  <p>Although it works, we need to write another python file, the requirement is to afford single file to users, so how it makes, I remember I have once saw some kind of realize which combine shell and python code, could anyone also know that &amp; give me some clue?</p>