I'd like to write an extension for Devise that allows you to use parse_resource as the datastore (as opposed to ActiveRecord). parse_resource is a Ruby wrapper for Parse.com's REST api. It's interface is pretty much the same as ActiveRecord's and is ActiveModel complaint. Because of this, it seems possible that an extension for Devise may not require too much non-boilerplate.
However, I can't find any tutorials. All I have to rely on are the sources for other extensions. From the MongoMapper extension, I gather that there are two main parts:
The generators (not quite required)
Here you overwrite
DeviseGenerator#(generate_model|inject_devise_content|replace_default_devise_orm)
methods.The "guts" (very much required)
I'm not quite as sure what's going on here. It seems that there's a lot of boilerplate, with a little bit of custom type-casting, and at the bottom there's a declaration that we'll be using this extension instead of the default ORM.
Is that all there is to it? What am I missing? Can someone explain what happens in "the guts" in a bit more detail?
Are there any simple lint tests to run to ensure full compatibility with Devise?