After being frustrated (yet again) last week when attempting to use
the salted_login_generator in a new rails project, I have modified it
so that it works better for my needs. Since the
SaltedHashLoginGenerator wiki page seems to indicate many people are
frustrated by this package (which is very nice but has been broken
since rails 1.1.4 I think) I have gem-ified my version of the
generator and released it. In my version:
* All of the tests pass on Rails 1.1.[456].
* Example DB schema uses migrations.
* The first_name, last_name attributes have underscores.
* Includes a quick start zip of preconfigured default rails app
files.
* The README_USER_LOGIN tells you everything you need to know.
It is available at
http://akuaku.org/code/login_sugar_generator-0.9.1.gem
This was my first time looking at the internals of generators and
gems, but I think I got it mostly right. It seems to work in fresh
rails projects in my tests. It's probably brittle in terms of naming
the controllers though, so you may have to make some adjustments if
you use something other than User and Localization as your controller
names.
I realize Deirdre Saoirse Moen has taken over the salted login project
and a fixed version 1.1.2 will probably be out soon, so just consider
this a measure of temporary sanity.
Updated on September 6: Making a last minute change before releasing and running off to Burning Man for a week is never a good idea is it? Version 0.9.1 released to fix the missing last_name references. Thanks BobF!