Getting OptionParser::InvalidOption error while installing rails

Hi,

Topic : Ruby On Rails
Issue : Error while installing rails using rubygems.

Description:

Am using ruby 1.9.3p194 and rubygems-2.1.7 on Ubuntu 12.0.

Getting the below error when trying to install Rails using rubyGems.

gem install rails --include-dependencies
ERROR: While executing gem ... (OptionParser::InvalidOption)
    invalid option: --include-dependencies

Any sort of help is much appreciated.

Regards,
Muralitharan A

Hi,

Topic : Ruby On Rails
Issue : Error while installing rails using rubygems.

Description:

Am using ruby 1.9.3p194 and rubygems-2.1.7 on Ubuntu 12.0.

Getting the below error when trying to install Rails using rubyGems.

gem install rails --include-dependencies
ERROR: While executing gem ... (OptionParser::InvalidOption)
    invalid option: --include-dependencies

Is --include-dependencies a valid flag?

I don't see it when I call

gem help install

from the command line

There is not a Ubuntu 12.0. Perhaps you mean 12.04. I recommend
using rvm to install and manage RoR. https://rvm.io/

Others suggest rbenv but I have no experience of that.

Colin

Colin Law wrote in post #1129611: