Forum: Ruby on Rails Error trying to execute Rails in Fedora Core 6

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
9fd06f0bb22626a61d91ad8296e8f10d?d=identicon&s=25 Leonardo (Guest)
on 2007-03-30 21:32
(Received via mailing list)
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
583c3d751af6c13d910b4fa8c6ef065d?d=identicon&s=25 Justin Mazzi (Guest)
on 2007-03-31 02:26
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.
9fd06f0bb22626a61d91ad8296e8f10d?d=identicon&s=25 Leonardo (Guest)
on 2007-04-02 13:20
(Received via mailing list)
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 Mazzi <rails-mailing-l...@andreas-s.net>
9fd06f0bb22626a61d91ad8296e8f10d?d=identicon&s=25 Leonardo (Guest)
on 2007-04-02 13:21
(Received via mailing list)
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 Mazzi <rails-mailing-l...@andreas-s.net>
5896cb49b1b972647009cf4f0b110852?d=identicon&s=25 Justin Mazzi (jmazzi)
on 2007-04-02 14:56
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 Mazzi <rails-mailing-l...@andreas-s.net>

It should be something like this:

#!/usr/local/bin/ruby
A2c85dc5ee81b12e3cc0a6522e8d079d?d=identicon&s=25 Chris Hall (au5lander)
on 2007-04-02 16:42
(Received via mailing list)
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
This topic is locked and can not be replied to.