Saturday, January 17, 2015

Fixing homebrew after installing Yosemite

Well...well...installing Yosemite broke homebrew.  Big surprise.  I figured out how to fix it by checking out:

http://apple.stackexchange.com/questions/153790/how-to-fix-brew-after-its-upgrade-to-yosemite

>$ brew
/usr/local/bin/brew: /usr/local/Library/brew.rb: /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby: bad interpreter: No such file or directory
/usr/local/bin/brew: line 23: /usr/local/Library/brew.rb: Undefined error: 0
>$ cd /usr/local/Library
>$ ls
Aliases/       Contributions/ ENV/           Formula/       Homebrew/      LinkedKegs/    Taps/          brew.rb*
>$ git pull origin master

...bunch of stuff...

Then you can run 'brew update'.

Tuesday, January 6, 2015

Understanding Python's With Statement

Turns out the 'with' statement in Python is fairly straight forward.  Here is an article (oldie but goodie) that gives a quick thumbnail sketch of how that statement works:

http://effbot.org/zone/python-with-statement.htm

On another note, this is the first blog of the New Year!