Reputation: 457
I installed Ruby and Rails and set-up the PATH to "C:\Rails\Ruby2.3.0\bin", but when I try to run commands with rails
, I get the error message:
The System cannot find the path specified.
I am able to run commands using ruby
, and rails
works if I use GitBash. How do I make it work on my normal command line?
Upvotes: -1
Views: 2101
Reputation: 144
If it's a simple question of locating the rails executable on Windows, then on later installs that use msys64 instead of DevKit, you'll find rails at the following folder:
c:\msys64\o-rdoc
Add this to your PATH or execute from that folder.
Your path may vary on 32-bit systems or if you changed the default install folder.
Upvotes: 0
Reputation: 11
Had the same problem here, installed the same way. Couldn't even run rails commands on GitBash, only way was going in C:\Rails\Ruby2.3.0\bin
through cmd and typing, for example, ruby rails new projectname
. The rails new projectname
wouldn't work even in these conditions.
What I did was going in the Command Prompt with Ruby and Rails and entered gem install rails
(which did not work on cmd). I also did gem install bundle
. Both installed successfully and that fixed all consoles for me: cmd, GitBash (wasn't working for me), Command Prompt with Ruby and Rails and even cmder works with Rails now.
Hope this helps you. Cheers.
Upvotes: 1