From: Jonathan Cairns Date: 2013-02-07T00:40:23+09:00 Subject: Re: Ruby 1.9.3-p362 on Mac OSX --047d7b603bce92107b04d5100765 Content-Type: text/plain; charset=ISO-8859-1 The following: /usr/bin/env ruby should work, so it sounds like your $PATH environment variable doesn't contain the rvm bin path. Try running: source "$HOME/.rvm/scripts/rvm" That should do the trick for your current shell session, but you can add it to your .bashrc/.bash_profile to set up the environment variable each time you open your terminal. Hope that helps. On 6 February 2013 14:31, Peter Bailey wrote: > Hi, > I've installed the latest Ruby on my Mac using Homebrew. When I type > "which Ruby" I get this: > > /Users/peterbailey/.rvm/rubies/ruby-1.9.3-p362/bin/ruby > > But, I can't use that as a shebang in my Ruby scripts. Can someone tell > me what I should use as a shebang in my Ruby scripts? None of these > work. > > #!/usr/bin/env ruby > #!/usr/bin/ruby > #!/usr/local/bin/ruby > > > Thanks, > Peter > > -- > Posted via http://www.ruby-forum.com/. > > -- *Jon Cairns* * * e-mail: jon@joncairns.com website: http://joncairns.com twitter: @joonty --047d7b603bce92107b04d5100765 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
The following:

= =A0 =A0 /usr/bin/env ruby

should work, so it= sounds like your $PATH environment variable doesn't contain the rvm bi= n path. Try running:

=A0 =A0 source "$HOME/.rvm/scripts/rvm= "

That should do the trick for yo= ur current shell session, but you can add it to your .bashrc/.bash_profile = to set up the environment variable each time you open your terminal. Hope t= hat helps.


On 6 Fe= bruary 2013 14:31, Peter Bailey <lists@ruby-forum.com> wr= ote:
Hi,
I've installed the latest Ruby on my Mac using Homebrew. When I type "which Ruby" I get this:

/Users/peterbailey/.rvm/rubies/ruby-1.9.3-p362/bin/ruby

But, I can't use that as a shebang in my Ruby scripts. Can someone tell=
me what I should use as a shebang in my Ruby scripts? None of these
work.

#!/usr/bin/env ruby
#!/usr/bin/ruby
#!/usr/local/bin/ruby


Thanks,
Peter

--
Posted via http://= www.ruby-forum.com/.




-- Jon Cairns

e-ma= il:=A0jon@joncairns.com
twitter= :=A0@joonty
--047d7b603bce92107b04d5100765--