From: Sam Duncan Date: 2013-06-27T13:04:33+09:00 Subject: Re: #!/usr/bin/env: No such file or directory This is a multi-part message in MIME format. --------------000506030900090403050203 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 27/06/13 15:58, Todd Sterben wrote: > I am new to both linux and ruby. I am using Ubuntu and Ruby 1.9 > > When I do which ruby, I get /usr/bin/ruby > When I do ruby -v I get ruby 1.9.3p0 (2011-10-30 revision 33570) > [i686-linux] > > When I try to kick off a simple script > > #!/usr/bin/env > > puts "Hello" > > I get > > ./test.rb: line 1: #!/usr/bin/env: No such file or directory > ./test.rb: line 4: puts: command not found > > > Why? > > Thanks > > Todd #!/usr/bin/env*ruby* Hope that helps. Sam --------------000506030900090403050203 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 8bit On 27/06/13 15:58, Todd Sterben wrote:
I am new to both linux and ruby.  I am using Ubuntu and Ruby 1.9

When I do which ruby, I get /usr/bin/ruby
When I do ruby -v I get ruby 1.9.3p0 (2011-10-30 revision 33570)
[i686-linux]

When I try to kick off a simple script

#!/usr/bin/env

puts "Hello"

I get

./test.rb: line 1: #!/usr/bin/env: No such file or directory
./test.rb: line 4: puts: command not found


Why?

Thanks

Todd

#!/usr/bin/env ruby

Hope that helps.

Sam
--------------000506030900090403050203--