Ruby on web

Hi all!
When I use rubt on web I need to put ‘#!/usr/bin/ruby’ in header, if
wiil use in my computer will be different, how can I use this
dynamically?

I’m not sure if I’ve understood your question, but if you are asking
about what to do if the path to ruby might be different, you can try:
#!env ruby

Paul L. wrote:

I’m not sure if I’ve understood your question, but if you are asking
about what to do if the path to ruby might be different, you can try:
#!env ruby

Yes, if I change the place where I execute ruby, the path maybe be
different…
but “#!env ruby” give me internal error at Apache.

2010/10/1 João Mello [email protected]

try
#!/usr/bin/env ruby

if that doesn’t work, type “whereis env” and let us know if env is in
the
same location on both computers.

Josh C. wrote:

2010/10/1 João Mello [email protected]

try
#!/usr/bin/env ruby

if that doesn’t work, type “whereis env” and let us know if env is in
the
same location on both computers.

I know it’s appear confusing, but when I use in my computer (Windows
running apache) I use “#!c:/ruby/bin/ruby.exe” in host I will need use
“#!/usr/bin/env ruby”

But if I use any diffenrt path in my computer I get this error:
Internal Server Error

The server encountered an internal error or misconfiguration and was
unable to complete your request.

I just want I way that I won’t need to change this all the time… (I
came form PHP/ASP.net :P)

Thanks a lot for helping!