Install Python
$ brew install readline sqlite gdbm
$ brew install python --universal --framework
$ python --version
Python 2.7
Symlinks...
| #!/usr/bin/env python | |
| """MailBox class for processing IMAP email. | |
| (To use with Gmail: enable IMAP access in your Google account settings) | |
| usage with GMail: | |
| import mailbox |
| import mock | |
| class AlmostAlwaysTrue(object): | |
| def __init__(self, total_iterations=1): | |
| self.total_iterations = total_iterations | |
| self.current_iteration = 0 | |
| def __nonzero__(self): | |
| if self.current_iteration < self.total_iterations: |
Install Python
$ brew install readline sqlite gdbm
$ brew install python --universal --framework
$ python --version
Python 2.7
Symlinks...
| # In case you had some strange python installation | |
| # NOTE: .pydistutils.cfg seems to be not compatible with brew install python | |
| # areas I needed to clean before installation | |
| # clean up ~/Library/Python | |
| # clean up .local | |
| # preconditions: | |
| # xcode with command line tools installed | |
| xcode-select --install |
| # Written by Brendan O'Connor, [email protected], www.anyall.org | |
| # * Originally written Aug. 2005 | |
| # * Posted to gist.github.com/16173 on Oct. 2008 | |
| # Copyright (c) 2003-2006 Open Source Applications Foundation | |
| # | |
| # Licensed under the Apache License, Version 2.0 (the "License"); | |
| # you may not use this file except in compliance with the License. | |
| # You may obtain a copy of the License at | |
| # |