Error trying to execute Rails in Fedora Core 6

Guys,
I am starting with RoR and was developing on windows environment.
Everything great.

Here at work we use FEdora, and, after installing, Ruby, RubyGems,
dependencies and Rails, all I get from the terminal is:

[leonardo@localhost ~]$ rails
/home/leonardo/apps/gems/rails-1.2.3/bin/rails: line 1: syntax error
near unexpected token (' /home/leonardo/apps/gems/rails-1.2.3/bin/rails: line 1:require
File.dirname(FILE) + ‘/…/lib/ruby_version_check’’

Any idea? I searched the web but didn’t find anything to clarify this
problem!

Thanks in advance!

Leo

Leonardo wrote:

Guys,
I am starting with RoR and was developing on windows environment.
Everything great.

Here at work we use FEdora, and, after installing, Ruby, RubyGems,
dependencies and Rails, all I get from the terminal is:

[leonardo@localhost ~]$ rails
/home/leonardo/apps/gems/rails-1.2.3/bin/rails: line 1: syntax error
near unexpected token (' /home/leonardo/apps/gems/rails-1.2.3/bin/rails: line 1:require
File.dirname(FILE) + ‘/…/lib/ruby_version_check’’

Any idea? I searched the web but didn’t find anything to clarify this
problem!

Thanks in advance!

Leo

make sure the top line in
/home/leonardo/apps/gems/rails-1.2.3/bin/rails is pointing to a copy of
ruby that exists.

this is the topline of rails file:

require File.dirname(FILE) + ‘/…/lib/ruby_version_check’

is anything wrong with it?

Thanks

On Mar 30, 9:26 pm, Justin M. [email protected]

this is the topline of rails file:

require File.dirname(FILE) + ‘/…/lib/ruby_version_check’

is anything wrong with it?

Thanks

On Mar 30, 9:26 pm, Justin M. [email protected]

I’m running rails on FC6. don’t know why your gems are installed in
your home directory or why you’re even running the rails file in that
bin dir. rails should be in /usr/bin.

how did you install rubygems in the first place?

everything ruby related should be located in /usr/lib/ruby on FC6 by
default.

these are the FC6 ruby packages you should have installed (latest
versions)

ruby-rdoc-1.8.5.35-1.fc6
ruby-devel-1.8.5.35-1.fc6
ruby-libs-1.8.5.35-1.fc6
ruby-irb-1.8.5.35-1.fc6
ruby-ri-1.8.5.35-1.fc6
ruby-1.8.5.35-1.fc6

Leonardo wrote:

this is the topline of rails file:

require File.dirname(FILE) + ‘/…/lib/ruby_version_check’

is anything wrong with it?

Thanks

On Mar 30, 9:26 pm, Justin M. [email protected]

It should be something like this:

#!/usr/local/bin/ruby