title: How to make Mac OS use the python installed by Homebrew
body: <p>I have searched online for a while for this question, and what I have done so far is </p>
  
  <ol>
  <li><p>installed python32 in homebrew</p></li>
  <li><p>changed my .bash_profile and added the following line to it:</p></li>
  </ol>
  
  <blockquote>
    <p>export PATH=/usr/local/bin:/usr/local/sbin:~/bin:$PATH</p>
  </blockquote>
  
  <p>but when I close the terminal and start again, I type 'which python', it still prints:</p>
  
  <blockquote>
    <p>/usr/bin/python</p>
  </blockquote>
  
  <p>and type 'python --version' still got:</p>
  
  <blockquote>
    <p>Python 2.7.2</p>
  </blockquote>
  
  <p>I also tried the following instruction:</p>
  
  <blockquote>
    <p>brew link --overwrite python</p>
  </blockquote>
  
  <p>or try to remove python installed by homebrew by running this instruction:</p>
  
  <blockquote>
    <p>brew remove python</p>
  </blockquote>
  
  <p>but both of the above two instructions lead to this error:</p>
  
  <blockquote>
    <p>Error: No such keg: /usr/local/Cellar/python</p>
  </blockquote>
  
  <p>can anybody help, thanks</p>