UPDATE FOR RAILS 3.0: After seeing what was available, I began developing my own Rails example apps. They’ve become quite popular, judging from the number of Rails developers visiting the GitHub repo. Each is accompanied by a detailed tutorial and an application template that can be used to generate a starter app. You can find them here.
THE ORIGINAL POST (from February 18, 2008):
I’m a firm believer that, as software developers, we always are standing on the toes of those who have gone before us.
So, in that spirit, I’m looking around for Rails example apps that I can use as a starting point for my own.
Many Rails books introduce Rails development through the process of building an example application. The best-documented Rails example apps are the ones in the books. I’ve looked through the books I have at hand. Most of the apps in the books are overly simple (for example, no authentication) or dated (no RESTful architecture).
I looked closely at RailsSpace. The authors Michael Hartl and Aurelius Prochazka fully document the steps to building a typical social networking web site. It is a full-featured app that is more complete than most tutorial applications. Unfortunately, the book was written before RESTful architectures became de rigueur. Only one part of the app is RESTful. Otherwise it might be suitable. UPDATE: Michael Hartl, one of the authors of RailsSpace, is leading development of an open source social network app, named Insoshi, which improves on RailsSpace.
I also looked at RailsCoders, the example app from the book Practical Rails Social Networking Sites, published by Apress. It’s a full-featured app and it is RESTful. The author chose to implement his own authentication (using RESTful principles); I would prefer to use the restful_authentication plugin. The app was written for Rails 1.2.3, not Rails 2.0, but an upgrade is relatively easy.
How about open source projects? I looked at a few.
I’ve used the Caboose Sample rails application on other projects, so that’s a potential starting point. The downside? It’s complex and not well documented. (The authors warn, “much of the code is targeted at an intermediate/advanced level”.)
A promising beginning point appears to be the Altered Beast forums application, a newer version of Beast. It’s RESTful. It uses Rails 2.0, rspec, and restful_authentication (with the acts_as_state_machine option). I also liked LovdbyLess, a free open source social network platform. It uses Rails 2.0 but not rspec or restful_authentication.
I posted here to ask for more recommendations.
UPDATE: I found an interesting example app named Jumpstart from the people at Relevance Inc. There’s also kickstart-rails from Mislav Marohnić. And I found RailsStarterApp from David Andrew Thompson and Six Hour Startup.
UPDATE: I’ve released my own Rails RESTful Authentication Example Application.