Postscripter
Postscripter

Reputation: 521

Rails server not running when using Rails gem version 3.2.9

I have created a new Rails project. And used the gem file used in the famous Michael Hartl tutorial

source 'https://rubygems.org'
   gem 'rails', '3.2.9'
   group :development, :test do
   gem 'sqlite3', '1.3.5'
   gem 'rspec-rails', '2.11.0'
end

# Gems used only for assets and not required
# in production environments by default.
group :assets do
gem 'sass-rails',   '3.2.5'
gem 'coffee-rails', '3.2.2'
gem 'uglifier', '1.2.3'
end

gem 'jquery-rails', '2.0.2'

group :test do
gem 'capybara', '1.1.2'
end

group :production do
gem 'pg', '0.12.2'
end

When running rails server am received this error message:

could not find gem rails in the gems available on the machine run bundle install..

I know am running on rails 3.2.9 I have checked with the command rails -v what is going wrong? Am using Windows 7 - 64 bits. am a ruby on rails newbie. When I change to gem rails 3.2.8 no more errors appear and rails server run successfully.

Further errors I remember getting through my trials of adding gems and running bundle install bundle update..etc

when i run bundle install as suggested by the 'console', many different errors start to appear! first:

em::Package::FormatError: no metadata found in..../activerecord -3.2.9 and bundler cannot continue. make sure that gem install activerecord -v '3.2.9' succeeds before bundling

Then I have tried to add the gem to my gem file and run bundle install again and then I got error asking for activesupport gem. I have added that to the gem and run bundle install again, tried with bundle update .. keep getting erros, also asking for railties gem...etc

Upvotes: 0

Views: 799

Answers (3)

Postscripter
Postscripter

Reputation: 521

uninstalled Railsinstaller and related leftovers folders. reinstalled Railsinstaller and problem solved.

Upvotes: 0

pjammer
pjammer

Reputation: 9577

bundle exec rails console should just give you a console, if you ran bundle in the rails root directory.

Upvotes: 0

nathanvda
nathanvda

Reputation: 50057

My guess is something went wrong with the installation of the rails gem. Uninstall rails (version 2.3.9) and install again (run bundle). Or if you use rvm, start in a clean gemset.

Upvotes: 0

Related Questions