Fix for “Couldn’t find ‘authenticated’ generator”

Be Sociable, Share!

    Here’s another little problem I was just hitting and the solution in case it happens to help someone else out there.

    If you’re trying to use a plugin (in this case the restful_authentication plugin) and you’re hitting an error like this when you use ./script/generate:

    “Couldn’t find ‘authenticated’ generator”


    Check to make sure that you have actually installed the plugin.

    In my case, I’d done something like this:

    matt@tigger:~/work/rails/streetloop$ script plugin install http://svn.techno-weenie.net/projects/plugins/restful_authentication/
    Script started, file is plugin
    matt@tigger:~/work/rails/streetloop$

    I’d assumed this had installed the plugin, but I don’t think it had.

    The correct syntax seemed to be this:

    script/plugin install restful_authentication

    [Note the use of the name of the plugin instead of the URL as before.]

    This resulted in much more promising-looking output:

    matt@tigger:~/work/rails/streetloop$ script/plugin install restful_authentication
    + ./README
    + ./Rakefile
    + ./generators/authenticated/USAGE
    + ./generators/authenticated/authenticated_generator.rb
    + ./generators/authenticated/templates/activation.html.erb
    + ./generators/authenticated/templates/authenticated_system.rb
    etc.

    Sure enough, with that installed, ./script/generate worked fine.

    Hope that helps you too.

    Be Sociable, Share!

      Comments

      1. Thanks for this, Matt. It came up as the top result for the string as was exactly what I was looking for. Thank you!

      2. Thanks mate, perfect

      3. Thanks Matt, in my case I am using Ruby with Eclipse under Windows, when I run script/plugin install git://github.com/technoweenie/restful-authentication.git a windows command prompt shows up and then goes away, I though it was installed than I tried to run script/generate authenticated user sessions and I got the “Couldn’t find ‘authenticated’ generator” error, so I tried your suggestion but didn’t came up neither, so i tried to reinstall the plug-in by calling script/plugin install git://github.com/technoweenie/restful-authentication.git --force and the windows command prompt shows up and now it did show a more promising-looking output :)
        Thanks.

      4. Hi for windows users,
        to install the restful authentication plugin for a ror project under Windows, i have downloaded the archive of restful_authentication from the url http://github.com/technoweenie/restful-authentication and past its content to the restful_authentication directory under the vendor/plugins directory of your project.
        after that i have lunch the command :
        ruby script/generate authenticated user sessions –include-activation

        that’s all

        Thanks for all.

      5. as AWIJOK mentioned,
        make sure you move the downloaded files to vendor/plugins

        i believe rails looks in there by default.

        thanks,

      Speak Your Mind

      *