Thursday, July 6, 2006

Comatose v0.4

I’ve just checked in a big update for Comatose.

Here’s a list of the major changes from the CHANGELOG:

[version 0.4]
* Added keywords field
* Abstracted text filters into a micro plugin structure, default
support for
- Textile
- Markdown
- RDoc
* It will only show the filters as a choice in the admin if you have
the necessary libraries for the filters to function.
* Added ComatoseController.hidden_meta_info = [] as a way of showing/hiding
the meta fields
* The comatose_migration generator now accepts an --upgrade flag which
will create a micro migration that only has the new fields in it
* get_root_page will now support returning an array of root pages to show
in the admin page list
* Created some initial tests... (Can you tell I'm not a test _first_ guy?)
* Inline rendering now handles :silent flag -- it will just return and
empty string if :silent=>true
* Modified all the internal references to ComatoseController to self.class.
The views reference controller.class. Redirects redirect to :controller=>
self.controller_name or controller.controller_name (action and view
respectively). This show allow you to sub-class the ComatoseController.

As always, I’ve tried to keep the README up to date with the changes.

Upgrading from the previous version...

I’ve added a couple of fields to the comatose page model… If you have already installed the comatose plugin, and have the add_comatose_support migration applied, you can get a migration of just the new fields by running:

$ ./script/generate comatose_migration --upgrade

There’s only one other feature that I know I’m going to add in the near future—The ability to re-order the pages. It won’t be a big deal when I release that one though, I already have the field I need in there.

Feedback

As always, check it out, kick the tires, etc. Let me know if you have any issues/questions/suggestions…. darthapo at gmail dot com

Sunday, July 2, 2006

Comatose Screenshots

I've had some requests for screenshots of the administration ui... So, without further ado, here they are.

Page ListPage DeletePage EditPage Edit - MorePage Edit - ReparentingPage Edit - Preview

Hmmm... After looking at the screenshots myself, I think I'm going to re-label "Expire Page Cache" to "Clear Page Cache". But still, you get the idea. That's the default administration ui that comes out of the box. It's straight CSS -- no images.

You can, however, completely customize it to look like your application by running:

$ rake comatose:customize

That will copy all the necessary files to your application folders for customization. The README talks more about that.

From Version 0.5

Update! The following screen shots are from version 0.5:

New-Page-ListNew-Page-Reordering

Technorati Tags: , ,

Comatose Update

There’s a new version of Comatose, the micro CMS plugin, out there.

I wanted to give you guys a quick heads up. This new version has a couple of breaking changes… After this release, if there are any data model changes, I’ll add a generator to the plugin that will create an ‘upgrade’ migration so you can update smoothly. But I’m hoping since it’s only been a few hours since the initial release, not too many people will have to revert anything!

If you’re not sure what Comatose is, you can read my last post on it for the background.

New Features

  • Hierarchal pages
  • Updated administration styles
  • Page previews
  • ERB pre-processing

Installation

$ ./script/plugin source http://mattmccray.com/svn/rails/plugins
$ ./script/plugin install comatose
$ ./script/generate comatose_migration
$ rake migrate

Add to the bottom of your config/routes.rb file:

map.comatose_root ''

That’s it—you’re good to go.

There’s a lot more info, and an FAQ example, in the README.

Saturday, July 1, 2006

Comatose, a Micro CMS Plugin

Features:

  • Easy to install—It’s a Rails plugin
  • Light-weight—It only adds one table to your schema (and has a generator to create the migration for you)
  • Runs entirely from the plugin folder by default
  • Intelligent page caching
  • Easy to leverage throughout your application
  • Full administration UI that can be re-skinned
  • Supports Textile filtering
  • Simple ‘mounting’ of the cms root path in your routes.rb file
  • Easy to wrap content in a Rails layout
  • It’s not meant to be a feature-complete CMS system. If this bugs you… Well, you should look into something like Radiant
  • No versioning support
  • No page status, all pages are ‘live’

Lately, I’ve had a recurring issue arise on my projects: They generally require a few content pages. Nothing fancy. Just a privacy policy, terms & conditions, an FAQ, that kind of thing.

I don’t really want to make these static HTML pages. They are likely to change at some point, especially the FAQ. Plus, I’d like to have them leverage Rails’ layout support. At the very least, I’d like to have them easy to re-skin.

That said, I don’t want to spend the time integrating an actual CMS system into the application. And really, for just a few pages, it’s too much.

I wanted an easier way. Something that was tiny, simple, and lightweight. Something I could drop into existing applications. In short; a micro CMS plugin.

They say necessity is the mother of invention, although I’ve often thought laziness is… But that’s a different post altogether. The point is, I wound up building something to suit my needs—perhaps it’ll suit yours as well.

I call it Comatose.

Comatose? What a Horrible Name!

Yeah, probably so. I just wanted something unique with the letters CMS in it. Comatose is the first one I thought of.

Features

  • Easy to install—It’s a Rails plugin
  • Light-weight—It only adds one table to your schema (and has a generator to create the migration for you)
  • Runs entirely from the plugin folder by default
  • Intelligent page caching
  • Easy to leverage throughout your application
  • Full administration UI that can be re-skinned
  • Supports Textile filtering
  • Simple ‘mounting’ of the cms root path in your routes.rb file
  • Easy to wrap content in a Rails layout
  • It’s not meant to be a feature-complete CMS system. If this bugs you… Well, you should look into something like Radiant
  • No versioning support
  • No page status, all pages are ‘live’

Installation  

Quite simple. Just run the following in your console, at your application’s root folder:

./script/plugin source http://mattmccray.com/svn/rails/plugins
./script/plugin install comatose
./script/generate comatose_migration
rake migrate

Comatose is now installed and setup.

Usage

To enable it in to your application, just add a line to your config/routes.rb file:

map.comatose_root '/pages'

That’s it! Now, whenever you visit http://your-app-url/pages it will render your cms pages.

Have a look at the README for more.

Feedback

Feel free to use Comatose. I’ve released it, at this point, under the MIT license. Which basically means you can use it however you want.

If you like it, hate it, or have some ideas for new features, let me know! ( darthapo at gmail dot com )