views:

339

answers:

4

I'm trying to get Devise up and running with a freshly generated Rails 2.3.8 app.

This is the error I'm running into:

devise > script/generate devise_install
Couldn't find 'devise_install' generator

I do have the Devise and Warden gems specified in my config file:

config.gem 'warden', :version => '0.10.7'
config.gem 'devise', :version => '1.0.8'

The gems are installed:

devise > rake gems 
 - [I] warden = 0.10.7
    - [R] rack >= 1.0.0
 - [I] devise = 1.0.8
    - [I] warden ~> 0.10.3
       - [R] rack >= 1.0.0
I = Installed
F = Frozen
R = Framework (loaded before rails starts)

Looking at the list of generators, I don't see anything from Devise:

devise > script/generate
Installed Generators
  Rubygems: cucumber, facebook, facebook_controller,
facebook_publisher, facebook_scaffold, feature, integration_spec,
publisher, rspec, rspec_controller, rspec_model, rspec_scaffold,
session, xd_receiver
  Builtin: controller, helper, integration_test, mailer, metal,
migration, model, observer, performance_test, plugin, resource,
scaffold, session_migration

Any clues?

A: 

Hey Chris,

i've seen the same error before. Here is the solution github issue tracker This might help you.

Petr

praethorian
+1  A: 

I ran into the same problem myself and, unfortunately, didn't ever get it fixed. But I did manage to find a pretty simple workaround.

The tasks the generators perform are typically pretty straightforward. So manually reproducing the same result shouldn't be a big deal if you just take a look at the generator code.

The devise_install generator in your example above just copies devise.rb to config/initializers/devise.rb and en.yml to config/locales/devise.en.yml

If you take a look at the other generators I'm sure you can figure them out easily enough as well.

aNoble
This is correct. You do not even need the locals/en.yml file unless you want to customize the flash messages/errors
Sam
A: 

seems to be working using devise 1.0.7

A: 

Hi Chris!

The same problem occurred with me, because I'm already had installed devise (a version ahead of 1.0.8). I just uninstall the devise ahead version.

Now my enviroment has only devise 1.0.8 and it works very well. :)

Fabrício