views:

33

answers:

1

Is there a pattern or a gem (Ruby on rails) for modeling the wiki-like behaviour of a StackOverflow like web site?

I'm working on Ruby-on-Rails project so a gem or something in RoR would be appreciated but a well defined pattern is just as good.

Thanks

+1  A: 

Did you try act_as_versioned? It is available as a gem, and adds simple versioning to any ActiveRecord model.

If you need more features, act_as_revisable might be interesting. According to the link, it adds the following features on top of act_as_versioned:

  • Pervasive Callbacks
  • Branching and Changesets
  • Deletes can be stored as a revision
  • Explicit is better than implicit
  • All data for a model is stored in one table
  • Wrapping up, requirements and installing
Jørn Schou-Rode