Comatose is a micro CMS, implemented as a Rails plugin, that is designed to be easy to embed and extend.
Comatose is a micro CMS designed for being embedded into existing Rails applications.
It's intended for simple CMS support. Comatose supports
It's meant to be lean, mean, easily embedded, and easy to re-skin for existing applications. If you need something more, I would recommend looking into Radiant.
For more information, see the Getting Started guide.
acts_as_versionedgems are required (at the moment)
NOTE: This is an active branch of Comatose that is built specifically for Rails 3.0. I will probably remove any legacy support.
ComatoseAdminControllerto reduce number of DB calls for building the page tree
Comatose.configureneeds to be an initializer (update docs)
$ rails plugin install git://github.com/niciliketo/comatose.git $ rails generate comatose $ rake db:migrate
routes.rband move the following comatose route to the bottom:
That's it, you're ready to go! You should be able to browse to http://127.0.0.1:3000/comatose_admin and start adding pages to your CMS. Browsing to http://127.0.0.1:3000/ will render your comatose pages if routing doesn't match any of your controllers.
NOTE: This is an experimental 2.0 branch, so upgrading is possible at the moment, but these instructions may not work for much longer.
If you are upgrading from an older version of Comatose (version 0.3, 0.4, 0.5, or 0.6), then you will need to re-install the comatose plugin and run:
$ ./script/plugin remove comatose $ ./script/plugin install comatose $ ./script/generate comatose_migration --upgrade --from=VERSION $ rake migrate
Note: Be sure to set the
--fromparameter to the version of Comatose you last had installed. Also, you only need to first two digits, including the dot, of the version you are upgrading from. For example, if you're upgrading from version 0.6.9 you can use:
$ ./script/generate comatose_migration --upgrade --from=0.6
This will create the upgrade migration(s) for you. It just adds the new fields, so you can keep the original migration comatose created.
You configure Comatose in your
config/environment.rbfile. Here is an example configuration block:
Comatose.configure do |config| # Sets the text in the Admin UI's title area config.admin_title = "Site Content" config.admin_sub_title = "Content for the rest of us..." end
Here's an example that uses the
AuthenticationSystemas generated by the
Comatose.configure do |config| # Includes AuthenticationSystem in the ComatoseController config.includes << :authenticated_system
config.admin_title = "Comatose - TESTING" config.admin_sub_title = "Content for the rest of us..."
Includes AuthenticationSystem in the ComatoseAdminController
config.admin_includes << :authenticated_system
Calls :login_required as a before_filter
config.admin_authorization = :login_required
Returns the author name (login, in this case) for the current user
config.admin_get_author do current_user.login end end
This plugin includes the work of many wonderful contributors to the Railsphere. Following are the specific libraries that are distributed with Comatose. If I've missed someone/something please let me know.
I’ve released Comatose under the MIT license. Which basically means you can use it however you want.
Don't forget to read the Getting Started guide located on the RubyForge project site.
If you like it, hate it, or have some ideas for new features, let me know!
matt at elucidata dot net