I\'m setting up my first Rails 4.1 app, which comes with Spring, their new preloader. When I try to install Devise using their generator ($ rails generate devise:insta
Check directories of some other projects that you were working on at that time, chances are that the generated files ended up there.
spring seems to get confused when you work with more than one rails app at a time. That's probably what caused your problem
spring runs as a server and keeps a rails environment loaded. I think what happens is that if you work with more than one project at a time then spring system seems to get confused and uses wrong environment.
I have had a situation where I was running rails g ... in one project and the files were getting generated in another project. What was crazy was that I kept renaming and moving that other folder, and still the generator kept putting the files in that folder. As if spring had latched on the the inode of that folder.
Try DISABLE_SPRING=1 rails g devise:install
or ps aux |grep spring and kill all the processes you see and then run rails g devise:install
We are taking out spring from the Gemfile for now while this broken behavior persists, and in the future use rails new --skip-spring
If you want to keep using spring, then try following these rules
rails new blog, work on it, then mv blog blog.old and rails new blog again, it might not work.