Enable tab completion on a Mac

This fix enables tab completion on a Mac.

See links for background:
  http://stackoverflow.com/a/7116997/541202
  http://docs.python.org/2/library/readline.html