From: matt@... (matt neuburg) Date: 2007-06-26T06:15:09+09:00 Subject: Re: OS X reads builtin version of ruby Herb Fitz wrote: > Ok, so i've tried to install 1.8.6 in a few ways, the first was building > it from source and most recently using macports. I've added the correct > lines to both my /etc/profile and ~/.bash_login. Whenever I reload these > files manually I get the correct version of ruby by issuing the version > command. Can anyone help? I searched the forum for my question but had > difficulty finding an answer. Sorry if this has been asked a million > times. What are you actually saying in order to invoke ruby, and where are you invoking it from? The Terminal, for example, is not the same BBEdit. I can only tell you what I did after installing ruby 1.8.5 in /usr/local/bin, which was to edit my .bash_profile (not my .bash_login) to include this line: PATH="/usr/local/bin:/usr/local/sbin:/usr/local/mysql/bin:$PATH" Here is some output in my terminal: $ echo $PATH /usr/local/bin:/usr/local/sbin:/usr/local/mysql/bin:/bin:/sbin:/usr/bin: /usr/sbin $ which ruby /usr/local/bin/ruby $ ruby --version ruby 1.8.5 (2006-08-25) [powerpc-darwin8.7.0] $ ruby -e 'puts ENV["PATH"]' /usr/local/bin:/usr/local/sbin:/usr/local/mysql/bin:/bin:/sbin:/usr/bin: /usr/sbin TextMate uses the same shell, so things work there too. But in BBEdit if I just want to use the Run command, I must start the script with an explicit shebang line: #! /usr/local/bin/ruby And even then it does not pick up the new PATH. The solution to *that* is to edit .MacOSX/environment.plist. You must provide a full, explicit PATH value (there is no variable expansion here). m. -- matt neuburg, phd = matt@tidbits.com, http://www.tidbits.com/matt/ Tiger - http://www.takecontrolbooks.com/tiger-customizing.html AppleScript - http://www.amazon.com/gp/product/0596102119 Read TidBITS! It's free and smart. http://www.tidbits.com