Error starting HTTP server in Ruby

Asked

Viewed 134 times

0

Hello guys I’m new with Ruby and I’m trying to create my first project but when I will start the server with the command rails server i get this mistake:

João@joao-note MINGW64 ~/Documents/Desenvolvimento/Rails/Primeiro_Projeto/hello (master)
$ rails server
C:/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/definition.rb:22:inbuild': C:/Users/Joǜo/Documents/Desenvolvimento/Rails/Primeiro_Projeto/hello/Gemfile not found (Bundler::GemfileNotFound)
from C:/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler.rb:120:in definition'
from C:/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler.rb:88:insetup'
from C:/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/setup.rb:18:in <top (required)>'
from C:/RailsInstaller/Ruby2.2.0/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:128:inrequire'
from C:/RailsInstaller/Ruby2.2.0/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:128:in rescue in require'
from C:/RailsInstaller/Ruby2.2.0/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:39:inrequire'
from C:/Users/João/Documents/Desenvolvimento/Rails/Primeiro_Projeto/hello/config/boot.rb:3:in <top (required)>'
from bin/rails:3:inrequire_relative'
from bin/rails:3:in <main>

I already installed Bundle with the command bundle install

But I still have this mistake. Does anyone know why?

Thanks in advance for the help.

Hugs

  • Your project has the Gemfile?

  • Yes @Luizcarvalho is with him and this in the project folder. Need me to post the file here? Thanks.

  • Post the project structure. You can use the Tree

  • @Luizcarvalho what is this Tree? Sorry for the question. I don’t know =/

  • I sent his link there in the comment. It serves to show the structure of a directory.

2 answers

1

You could reinstall Ruby in another way.. I’ve used railsInstaller but didn’t like it very much.. you can try installing by here(Download the devkit compatible with the version), even the same version. After downloading extract the dev kit, access the extracted folder through the terminal and run:

ruby dk.rb init

ruby dk.rb install

gem install rails

Access your project folder from the terminal and run

bundle install

0

I reinstalled the source code and it all worked out.

Thank you all.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.