Skip to content

Ruby Tuesday

Except it’s Monday. So today I am working from home in order to bootstrap my brain quickly up into a better understanding of Pig. First order of business being to install it locally. A quick Google and I find a number of resources talking about how to install Hadoop and Pig, two of the top three involving using HomeBrew:

 

  1. https://www.getblueshift.com/setting-up-hadoop-2-4-and-pig-0-12-on-osx-locally/
  2. http://amodernstory.com/2014/09/23/installing-hadoop-on-mac-osx-yosemite/
  3. http://blog.shelan.org/2014/10/how-to-install-hadoop-standalone-2xx-on.html

Of course, the first thing I test is whether I have HomeBrew installed:

Rozencrantz-2:~ robert$ 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 26: /usr/local/Library/brew.rb: Undefined error: 0

Sigh. This remains the big flaw with software as bazaar rather than software as cathedral: it is a frequent experience that sitting down to do anything will first involve a run-around getting tools fixed and replaced before actually starting.

Fortunately it looks like there’s a known work around so we will see how that goes:

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

Addendum:
That seems to have worked. Since I’d at some point in the past installed Brew the right way (for whatever values of Right Way you choose), then it as a matter of doing the following:

cd /usr/local/Library
git pull origin master
brew update

After that it was possible to see that brew.rb now has the correct hash-bang:

#!/System/Library/Frameworks/Ruby.framework/Versions/Current/usr/bin/ruby -W0

Post a Comment

Your email is never published nor shared. Required fields are marked *
*
*